Add nvmrc hook on chpwd
This commit is contained in:
1 parent
0f4492a5ec
commit
3a7e3bb618
1 file changed
+9
-1
@@ -1 +1,9 @@
|
|||||||
# oh-my-zsh complains without a .zsh file in here
|
# oh-my-zsh complains without a .zsh file in here
|
||||||
|
|
||||||
|
autoload -U add-zsh-hook
|
||||||
|
load-nvmrc() {
|
||||||
|
if [[ -f .nvmrc && -r .nvmrc ]]; then
|
||||||
|
nvm use
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
add-zsh-hook chpwd load-nvmrc
|
||||||
Reference in new issue
Block a user