This is the way I installed nodejs in ubuntu 14.04 LTS:
sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get install nodejs
When I c
Checkout nvm. It manages node distributions for you, so you can have multiple projects running that use different nodejs versions.
nvm
lets you choose exactly which version of node you need. With apt-get
you will always only get the latest version that has been included into debian/ubuntu
by those package maintainers, but those are usually very old. Especially in an area like nodejs, this is mostly not suitable.