This commit is contained in:
Shahar Or 2017-04-23 14:43:58 +00:00 committed by GitHub
commit 006ddb48f7

View file

@ -0,0 +1,15 @@
zsh-npm-path() {
if [[ ! -x $(which npm) ]]; then
# there is no npm
return
fi
if [[ ! -r $(which npm-path) ]]; then
echo "WARNING: npm-path must be available for the oh-my-zshell npm-path module to update your PATH. Perhaps \`npm --global install npm-path\` will help."
return
fi
export PATH=$(npm-path)
}
precmd_functions+="zsh-npm-path"