This commit is contained in:
isqua 2016-05-12 03:27:24 +00:00
commit ef61b68e33
2 changed files with 5 additions and 1 deletions

View file

@ -1,6 +1,9 @@
# get the node.js version
function nvm_prompt_info() {
[ -f "$HOME/.nvm/nvm.sh" ] || return
if [[ "$(command -v nvm)" != "nvm" || -z $(echo $PATH | grep "$HOME/.nvm") ]];
then return
fi
local nvm_prompt
nvm_prompt=$(node -v 2>/dev/null)
[[ "${nvm_prompt}x" == "x" ]] && return

View file

@ -1,3 +1,4 @@
# The addition 'nvm install' attempts in ~/.profile
[[ -s ~/.nvm/nvm.sh ]] && . ~/.nvm/nvm.sh
[[ -r $NVM_DIR/bash_completion ]] && . $NVM_DIR/bash_completion