This commit is contained in:
Harry Green 2020-07-16 14:54:51 +12:00 committed by Harry Green
parent 09c2d8a743
commit 42edfcd609
2 changed files with 22 additions and 1 deletions

View file

@ -44,7 +44,6 @@ zstyle ':prezto:load' pmodule \
'syntax-highlighting' \
'fasd' \
'autosuggestions' \
'node'
#
# Autosuggestions

View file

@ -44,3 +44,25 @@ export XDG_CACHE_HOME="$HOME/.cache"
# Disable command correction suggestions
unsetopt correct
# fnm (fast node manager)
export PATH=/Users/hgreen/.fnm/current/bin:$PATH
export FNM_MULTISHELL_PATH=/Users/hgreen/.fnm/current
export FNM_DIR=/Users/hgreen/.fnm
export FNM_NODE_DIST_MIRROR=https://nodejs.org/dist
export FNM_LOGLEVEL=info
autoload -U add-zsh-hook
_fnm_autoload_hook () {
if [[ -f .node-version && -r .node-version ]]; then
echo "fnm: Found .node-version"
fnm use
elif [[ -f .nvmrc && -r .nvmrc ]]; then
echo "fnm: Found .nvmrc"
fnm use
fi
}
add-zsh-hook chpwd _fnm_autoload_hook \
&& _fnm_autoload_hook