Skip to content Skip to sidebar Skip to footer

Can't Update Nodejs With The Sudo N Stable Trick, Cannot Stat Error (ubuntu 14.04)

I try the following : Installing npm and nodejs through apt. Installing the latest npm version, like : npm npm@install -g Ending up with nodejs version 0.10 or something, and

Solution 1:

There is a good manager that will help you with all node versions. It's called nvm(Node version manager).

https://github.com/creationix/nvm

All install guides are on git page. I install it like this.

curl -sL https://raw.githubusercontent.com/creationix/nvm/v0.31.0/install.sh -o install_nvm.sh

bash install_nvm.sh

Check to see if everything installed correctly

nvm --version

Then when you want update node you can just do

nvm install 6.9.1 (or any version you like)

nvm alias default 6.9.1

nvm use default

After restarting of your terminal run

node -v you should have 6.9.1 installed and used.

Hope this helps.

Post a Comment for "Can't Update Nodejs With The Sudo N Stable Trick, Cannot Stat Error (ubuntu 14.04)"