node.js nvm deactivate on uninstall

pull/507/head
Botspot 4 years ago
parent f13551a8c3
commit 7ba0421de8

@ -7,11 +7,14 @@ function error {
exit 1
}
#Uninstall NodeJS
#prepare to run nvm
export NVM_DIR="$HOME/.config/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
cd $NVM_DIR
#Uninstall NodeJS
nvm deactivate
nvm uninstall default || error "Failed to purge Node.JS!"
#Remove nvm

Loading…
Cancel
Save