Skip to content

Instantly share code, notes, and snippets.

@michiel
Created March 25, 2015 08:18
Show Gist options
  • Save michiel/e29cc1705ed7c61385bd to your computer and use it in GitHub Desktop.
Save michiel/e29cc1705ed7c61385bd to your computer and use it in GitHub Desktop.
nvm project-specific
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
# Try to load via project-specific .nvmrc
nvm use > /dev/null 2>&1
if [ $? -ne 0 ]; then
# Use default - set with 'nvm alias default v0.12.1'
nvm use default
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment