From b948e3630bb293993e314bcf2691a3ab5a9b23bc Mon Sep 17 00:00:00 2001 From: Sorin Ionescu Date: Mon, 13 Oct 2014 11:57:20 -0400 Subject: [PATCH] Load Homebrew installed NVM --- modules/node/init.zsh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/node/init.zsh b/modules/node/init.zsh index a489a54..6fedb3c 100644 --- a/modules/node/init.zsh +++ b/modules/node/init.zsh @@ -6,9 +6,13 @@ # Zeh Rizzatti # -# Load NVM into the shell session. +# Load manually installed NVM into the shell session. if [[ -s "$HOME/.nvm/nvm.sh" ]]; then source "$HOME/.nvm/nvm.sh" + +# Load package manager installed NVM into the shell session. +elif (( $+commands[brew] )) && [[ -d "$(brew --prefix nvm 2>/dev/null)" ]]; then + source $(brew --prefix nvm)/nvm.sh fi # Return if requirements are not found.