Skip to content

Instantly share code, notes, and snippets.

@hiro345
Created February 18, 2015 02:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hiro345/d89d32aa617609d170c0 to your computer and use it in GitHub Desktop.
Save hiro345/d89d32aa617609d170c0 to your computer and use it in GitHub Desktop.
Node.js install script for Ubuntu 14.04
#!/bin/sh
v=v0.12.0
node="node-${v}"
dst="$HOME/applications/node"
if [ ! -e "$dst}/src" ]; then
mkdir -p "${dst}/src"
fi
cd "${dst}/src"
wget http://nodejs.org/dist/${v}/${node}.tar.gz
tar xf ${node}.tar.gz
cd ${node}
./configure --prefix=${dst}/${node}
make && make install
cd "${dst}"
if [ -e node ]; then
rm node
fi
ln -s ${node} node
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment