-
-
Save randwa1k/9061221 to your computer and use it in GitHub Desktop.
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
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
. ~/.bashrc | |
mkdir ~/local | |
mkdir ~/node-latest-install | |
cd ~/node-latest-install | |
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
./configure --prefix=~/local | |
make install # this steps takes many minutes | |
# curl https://npmjs.org/install.sh | sh | |
# use this below instead to avoid install.sh newline error | |
curl -O https://www.npmjs.org/install.sh | |
# avoid this error: find: `/usr/local/lib/node': No such file or directory | |
sudo mkdir -p /usr/local/{lib/node,include/node} | |
sudo sh install.sh | |
Output of last command: | |
tar=/bin/tar | |
version: | |
tar (GNU tar) 1.26 | |
Copyright (C) 2011 Free Software Foundation, Inc. | |
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. | |
This is free software: you are free to change and redistribute it. | |
There is NO WARRANTY, to the extent permitted by law. | |
Written by John Gilmore and Jay Fenlason. | |
install npm@latest | |
fetching: http://registry.npmjs.org/npm/-/npm-1.4.3.tgz | |
0.10.25 | |
1.4.3 | |
cleanup prefix=/usr/local | |
All clean! | |
/home/ubuntu/.node/bin/npm -> /home/ubuntu/.node/lib/node_modules/npm/bin/npm-cli.js | |
npm@1.4.3 /home/ubuntu/.node/lib/node_modules/npm | |
It worked |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment