Fix loading of nvm for brew-installed nvm
This reverts to the original (working) version from 2017. During the most recent refactor to use the `_bash_it_homebrew_check` helper method, it was overlooked that `${BASH_IT_HOMEBREW_PREFIX}/nvm.sh` is not the equivalent to `$(brew --prefix nvm)/nvm.sh` since `BASH_IT_HOMEBREW_PREFIX` is set from `brew --prefix` instead of `brew --prefix nvm`.
pull/2162/head
parent
e38696a0ac
commit
8eb90f7ac1
|
|
@ -10,9 +10,9 @@ about-plugin 'node version manager configuration'
|
|||
|
||||
export NVM_DIR="${NVM_DIR:-$HOME/.nvm}"
|
||||
# This loads nvm
|
||||
if _bash_it_homebrew_check && [[ -s "${BASH_IT_HOMEBREW_PREFIX}/nvm.sh" ]]
|
||||
if _bash_it_homebrew_check && [[ -s "$(brew --prefix nvm)/nvm.sh" ]]
|
||||
then
|
||||
source "${BASH_IT_HOMEBREW_PREFIX}/nvm.sh"
|
||||
source "$(brew --prefix nvm)/nvm.sh"
|
||||
else
|
||||
[[ -s "$NVM_DIR/nvm.sh" ]] && source "$NVM_DIR/nvm.sh"
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in New Issue