How do I update node.js on debian using dpkg
I want to make sure I'm keeping node.js up to date on my debian system since it can still be somewhat buggy. Here's how I'll do it:
Check the current version
node --version
Remove the node installation:
sudo dpkg -r node
Build the latest for dpkg
sudo apt-get install python g++ make checkinstall
mkdir ~/src && cd $_
wget -N http://nodejs.org/dist/node-latest.tar.gz
tar xzvf node-latest.tar.gz && cd node-v*
./configure
checkinstall #(remove the "v" in front of the version number in the dialog)
sudo dpkg -i node_*
And, of course, verify that you have the latest version installed
node --version