Browse Source

fix: revert to npm install

NGPixel 7 years ago
parent
commit
e2d3057f57
4 changed files with 4 additions and 19 deletions
  1. 1 16
      npm/install.js
  2. 1 1
      npm/package-lock.json
  3. 1 1
      npm/package.json
  4. 1 1
      package.json

+ 1 - 16
npm/install.js

@@ -138,24 +138,12 @@ const tasks = {
       }
     })
   },
-  /**
-   * Install Yarn
-   */
-  installYarn() {
-    ora.text = 'Installing Yarn...'
-    return exec.stdout('npm', ['install', 'yarn'], {
-      cwd: installDir
-    }).then(results => {
-      ora.text = 'Yarn installed successfully.'
-      return true
-    })
-  },
   /**
    * Install npm dependencies
    */
   installDependencies() {
     ora.text = 'Installing Wiki.js npm dependencies...'
-    return exec.stdout('./node_modules/.bin/yarn', ['install', '--production', '--ignore-optional'], {
+    return exec.stdout('npm', ['install', '--only=production', '--no-optional'], {
       cwd: installDir
     }).then(results => {
       ora.text = 'Wiki.js npm dependencies installed successfully.'
@@ -259,9 +247,6 @@ Promise.join(
 }).then(() => {
   isContainerBased && console.info('>> Creating config file...')
   return tasks.ensureConfigFile()
-}).then(() => {
-  isContainerBased && console.info('>> Installing Yarn...')
-  return tasks.installYarn()
 }).then(() => {
   isContainerBased && console.info('>> Installing dependencies...')
   return tasks.installDependencies()

+ 1 - 1
npm/package-lock.json

@@ -1,6 +1,6 @@
 {
   "name": "wiki.js",
-  "version": "1.0.2",
+  "version": "1.0.3",
   "lockfileVersion": 1,
   "dependencies": {
     "amp": {

+ 1 - 1
npm/package.json

@@ -1,6 +1,6 @@
 {
   "name": "wiki.js",
-  "version": "1.0.2",
+  "version": "1.0.3",
   "description": "A modern, lightweight and powerful wiki app built on NodeJS, Git and Markdown",
   "main": "install.js",
   "scripts": {

+ 1 - 1
package.json

@@ -1,6 +1,6 @@
 {
   "name": "wiki",
-  "version": "1.0.2",
+  "version": "1.0.3",
   "description": "A modern, lightweight and powerful wiki app built on NodeJS, Git and Markdown",
   "main": "wiki.js",
   "scripts": {