mirror of
https://github.com/nvm-sh/nvm.git
synced 2025-05-11 14:51:49 +00:00
Merge e328281608
into 0d44ed1126
This commit is contained in:
commit
1b85a64442
@ -27,6 +27,8 @@ if [ ! -z "$1" ]; then
|
||||
else
|
||||
if [ -f "$HOME/.bash_profile" ]; then
|
||||
PROFILE="$HOME/.bash_profile"
|
||||
elif [ -f "$HOME/.bashrc" ]; then
|
||||
PROFILE="$HOME/.bashrc"
|
||||
elif [ -f "$HOME/.profile" ]; then
|
||||
PROFILE="$HOME/.profile"
|
||||
fi
|
||||
|
@ -27,6 +27,8 @@ else
|
||||
PROFILE="$HOME/.bash_profile"
|
||||
elif [ -f "$HOME/.zshrc" ]; then
|
||||
PROFILE="$HOME/.zshrc"
|
||||
elif [ -f "$HOME/.bashrc" ]; then
|
||||
PROFILE="$HOME/.bashrc"
|
||||
elif [ -f "$HOME/.profile" ]; then
|
||||
PROFILE="$HOME/.profile"
|
||||
fi
|
||||
@ -36,7 +38,7 @@ SOURCE_STR="[[ -s \$HOME/.nvm/nvm.sh ]] && . \$HOME/.nvm/nvm.sh # This loads NV
|
||||
|
||||
if [ -z "$PROFILE" ] || [ ! -f "$PROFILE" ] ; then
|
||||
if [ -z $PROFILE ]; then
|
||||
echo "=> Profile not found. Tried $HOME/.bash_profile and $HOME/.profile"
|
||||
echo "=> Profile not found. Tried $HOME/.bash_profile, $HOME/.bashrc, and $HOME/.profile"
|
||||
else
|
||||
echo "=> Profile $PROFILE not found"
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user