From bbe6649221e3adec752c56b7af4068868604db8d Mon Sep 17 00:00:00 2001 From: haixuanTao Date: Tue, 17 Sep 2024 14:32:13 +0200 Subject: [PATCH] Add a source command for reloading the path --- install.sh | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/install.sh b/install.sh index cbb8bbad..735b32cd 100755 --- a/install.sh +++ b/install.sh @@ -199,8 +199,9 @@ if [ "$SHELL" = "/bin/bash" ]; then if ! grep -q "$dest" ~/.bashrc; then echo "Adding $dest to PATH in ~/.bashrc" echo "export PATH=\$PATH:$dest" >> ~/.bashrc - source ~/.bashrc - echo "Path added to ~/.bashrc and reloaded." + echo "Path added to ~/.bashrc." + echo "Please reload with:" + echo " source ~/.bashrc" else echo "$dest is already in the PATH in ~/.bashrc" fi @@ -208,8 +209,9 @@ elif [ "$SHELL" = "/bin/zsh" ]; then if ! grep -q "$dest" ~/.zshrc; then echo "Adding $dest to PATH in ~/.zshrc" echo "export PATH=\$PATH:$dest" >> ~/.zshrc - source ~/.zshrc - echo "Path added to ~/.zshrc and reloaded." + echo "Path added to ~/.zshrc." + echo "Please reload with:" + echo " source ~/.zshrc" else echo "$dest is already in the PATH in ~/.zshrc" fi