Installing Node.JS through a PPA does not fetch the latest version
yeah yeah I know, this has been asked before. But when using the chris-lea
ppa or the "official way" (which I think is actually the same thing?), after installing you get this:
~$ node --version
v0.10.36
So what's the problem? Well the current version of node at the official website is already at 0.12. that seems like pretty large gap to me.
Is there any ppa that gets updated more frequently?
Solution 1:
Installation instructions are here: https://nodesource.com/blog/nodejs-v012-iojs-and-the-nodesource-linux-repositories
# Note the new setup script name for Node.js v0.12 curl -sL https://deb.nodesource.com/setup_0.12 | sudo bash - # Then install with: sudo apt-get install -y nodejs
Solution 2:
If you wish to be able to install multiple versions of node then NVM is for you.
To install version NVM and then after install version 0.12 of node:
curl https://raw.githubusercontent.com/creationix/nvm/v0.25.0/install.sh | bash
source ~/.bashrc
nvm install 0.12
Then to use:
nvm use 0.12
Always check https://github.com/creationix/nvm for new versions of NVM. When writing this the version was 0.25.0
I doubt it is the same if you read this.
Node Version Manager for the win.