Skip to content

Instantly share code, notes, and snippets.

@mbonaci
Created March 8, 2014 12:44
Show Gist options
  • Save mbonaci/9430028 to your computer and use it in GitHub Desktop.
Save mbonaci/9430028 to your computer and use it in GitHub Desktop.
Install `node` on fresh Ubuntu 13.04 using `nave` (without a subshell)
# contains mkdirhier
sudo apt-get install xutils-dev
# surprisingly Ubuntu doesn't come with curl
sudo apt-get install curl
# isaacs's nave:
# prepare nave dir and download install script
mkdir ~/.nave
cd ~/.nave
wget http://github.com/isaacs/nave/raw/master/nave.sh
sudo ln -s $PWD/nave.sh /usr/local/bin/nave
sudo chown $USER nave.sh
sudo chmod 711 nave.sh
# create links and take owneship
sudo mkdirhier /usr/local/{share/man,bin,lib/node,include/node}
sudo chown -R $USER /usr/local/share/man
sudo chown -R $USER /usr/local/bin
sudo chown -R $USER /usr/local/lib/node
sudo chown -R $USER /usr/local/include/node
# install the latest stable nodejs in the "main" root.
nave usemain stable
# or
nave usemain 0.11.9
# install npm
curl https://npmjs.org/install.sh | sh
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment