Reputation: 41
I installed node JS in linux virtual machine on my windows. The problem is I can't use npm like npm install -g node-inspector. But I think the error is because of my node version. My node JS version is 0.10.35. I tried below one. but it still doesn't work. The error message gyp WARN EACCES user "root" does not have permission to access the dev dir "~/.node-gyp/0.10.35"
sudo npm cache clean -f
sudo npm install -g n
sudo n stable
Upvotes: 2
Views: 1868
Reputation: 10818
You installed node
v0.10.35 in a Linux virtual machine. Assuming that node still works, here's how you can fix your npm.
curl https://www.npmjs.org/install.sh | sudo sh
This should get you a working npm
.
However, the error you report sounds more like a problem with node-gyp
and building native addons. If you are getting an error while running npm
, please upload the npm-debug.log
to https://gist.github.com and post a link to the gist in the npm
issue tracker at https://github.com/npm/npm/issues.
Thanks!
Upvotes: 0