conf2/zsh/.oh-my-zsh/plugins/nvm/nvm.plugin.zsh

9 lines
275 B
Bash
Raw Normal View History

2019-01-12 15:47:23 +00:00
# Set NVM_DIR if it isn't already defined
[[ -z "$NVM_DIR" ]] && export NVM_DIR="$HOME/.nvm"
2019-10-24 19:09:05 +00:00
# Try to load nvm only if command not already available
if ! type "nvm" &> /dev/null; then
# Load nvm if it exists
[[ -f "$NVM_DIR/nvm.sh" ]] && source "$NVM_DIR/nvm.sh"
fi