Guiding The Geek In You
Installing nodejs on Mint or Ubuntu is generally a smooth process. Nothing that will bend or break your mind – if you start with a clean slate – and assuming a recent build of Mint or Ubuntu!
Note for the paranoid like me: for the fresh install, we are going to add an “untrusted” PPA (personal package archive). Untrusted simply means that these archives are not overseen by the community at large, so using software from these resources could potentially break your system.
That said, I have used nodejs from Chris Lea’s PPA for months now with zero problems – he does a fantastic job!
Nodejs-dev and npm are included in the nodejs package as of v0.10.0 – another reason to use Chris Lea’s PPA.
Because the latest version of nodejs (or nodejs-dev or the npm) is not available in the default repo, remove any traces before you begin:
sudo apt-get remove nodejs nodejs-dev npm
Install the latest version of nodejs package:
sudo apt-get update
sudo apt-get install python-software-properties python g++ make
sudo add-apt-repository ppa:chris-lea/node.js
sudo apt-get update
sudo apt-get install nodejs
Check that nodejs version v0.10.20 (or better) installed correctly:
nodejs -v
Go ahead and check NPM as well (v1.3.11 or better):
npm -v
Thanks for reading!