Skip to content

Instantly share code, notes, and snippets.

@zsnmwy
Last active September 16, 2018 09:12
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 zsnmwy/01ac6182b703cab3b3ee4c5b4e45dcb4 to your computer and use it in GitHub Desktop.
Save zsnmwy/01ac6182b703cab3b3ee4c5b4e45dcb4 to your computer and use it in GitHub Desktop.
use nvm insatll node && npm install pm2
wget -qO- https://raw.githubusercontent.com/creationix/nvm/v0.33.8/install.sh | bash 1>/dev/null #This install nvm
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
nvm install 8.11.1 # This install node v8.11.1
nvm use 8.11.1
node -v # Show node version
npm i -g pm2 1>/dev/null # This install pm2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment