Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm install -g node removes node #74

Open
serapath opened this issue Sep 1, 2019 · 0 comments
Open

npm install -g node removes node #74

serapath opened this issue Sep 1, 2019 · 0 comments

Comments

@serapath
Copy link

serapath commented Sep 1, 2019

npm -v was 6.11.2
node -v was 12.9.1

I'm running npm install -g node and get:

npm WARN lifecycle npm is using /home/serapath/.npm-global/lib/node_modules/node/bin/node but there is no node binary in the current PATH. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.

> [email protected] preinstall /home/serapath/.npm-global/lib/node_modules/node
> node installArchSpecificPackage

sh: 1: node: not found
npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! [email protected] preinstall: `node installArchSpecificPackage`
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! Failed at the [email protected] preinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/serapath/.npm/_logs/2019-09-01T23_36_49_888Z-debug.log

how and/or why is this happening?

I quickly re-install the latest npm and node version with a little bash script:
https://github.com/serapath/node-and-npm/blob/master/install

...but afterwards, running npm install -g node causes the same issue again. The script itself actually even uses the very same commands to get and update to the latest versions so i'm very confused.

any pointers? :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant