Another reason to install it is to use Flask-CSS (and hence lesscss) which I mentioned in my last article, so I thought I'd better cover that now.
Let's install it in our home directory:
cd ~ rm -fr node # in case this is a fresh install sudo apt-get install -y g++ curl libssl-dev apache2-utils git-core wget http://nodejs.org/dist/node-v0.4.9.tar.gz tar xfz http://nodejs.org/dist/node-v0.4.9.tar.gz cd node-v0.4.9 && ./configure # or the bleeding edge version # git clone git://github.com/joyent/node.git # cd node && ./configure make sudo make install
and finally you need to add the following to your ~/.bashrc file:
export PATH="$HOME/node/bin:$PATH"
Finally install NPM (Node Package Manager):
source ~/.bashrc curl http://npmjs.org/install.sh | sudo sh
Simples!
Thanks to: