reactioncommerce / reaction-cli

A command line tool for working with Reaction Commerce.
33 stars 20 forks source link

Failed at the spawn-sync@1.0.15 postinstall script 'node postinstall'. #13

Closed ishallbethat closed 7 years ago

ishallbethat commented 7 years ago

HI I'm trying to install reaction-cli but the error keeps popping out. And i'm using ubuntu 14 also it's nvm installed and i'm using node executables, not nodejs.

How can you fix please ?

root@HelloMac~# npm install -g reaction-cli
npm WARN deprecated lodash.assign@4.2.0: This package is deprecated. Use Object.assign.

> spawn-sync@1.0.15 postinstall /root/.nvm/v4.5.0/lib/node_modules/reaction-cli/node_modules/inquirer/node_modules/external-editor/node_modules/spawn-sync
> node postinstall

module.js:340
    throw err;
          ^
Error: Cannot find module '/root/.nvm/v4.5.0/lib/node_modules/reaction-cli/node_modules/inquirer/node_modules/external-editor/node_modules/spawn-sync/postinstall'
    at Function.Module._resolveFilename (module.js:338:15)
    at Function.Module._load (module.js:280:25)
    at Function.Module.runMain (module.js:497:10)
    at startup (node.js:119:16)
    at node.js:902:3
npm ERR! Linux 4.4.0-38-generic
npm ERR! argv "/root/.nvm/v4.5.0/bin/node" "/root/.nvm/v4.5.0/bin/npm" "install" "-g" "reaction-cli"
npm ERR! node v4.5.0
npm ERR! npm  v2.15.9
npm ERR! code ELIFECYCLE

npm ERR! spawn-sync@1.0.15 postinstall: `node postinstall`
npm ERR! Exit status 8
npm ERR! 
npm ERR! Failed at the spawn-sync@1.0.15 postinstall script 'node postinstall'.
npm ERR! This is most likely a problem with the spawn-sync package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node postinstall
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs spawn-sync
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! 
npm ERR!     npm owner ls spawn-sync
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR!     /root/npm-debug.log
ishallbethat commented 7 years ago

The problem is fixed by installing nodejs instead. I was using node from nvm on ubuntu 14.04 and after i uninstalled node, nvm and installed nodejs, the problem disappear.

aaronjudd commented 7 years ago

@IamGabrielWu thanks! we should have asked for the output of reaction -v that usually helps identify if it's a node/version issue.. should we close this issue?