node and npm install without sudo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## make sure you use python2.x (recommended python2.7) | |
mkdir ~/local | |
mkdir ~/node-latest-install | |
cd ~/node-latest-install | |
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
export JOBS=8 # optional, sets number of parallel commands. | |
./configure --prefix=$HOME/local | |
#configure --prefix=$HOME/local/node | |
make | |
make install # ok, fine, this step probably takes more than 30 seconds... | |
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
curl https://www.npmjs.org/install.sh | sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment