Skip to content

Commit 44c83eb

Browse files
author
guanqun
committed
let's support zsh for real :)
`~/.profile` is not used for zsh FYI. Instead, `~/.zprofile` is used, but this file is only for login shell. We need to support interactive shell as well (I use PuTTY a lot...) I understand that there's always a workaround for zsh users to source the ~/.profile, but that requires an extra step for users. Using this code would make zsh users' life easier. :D
1 parent b169713 commit 44c83eb

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

install

+4
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@ echo ", Done."
3636

3737
if ! echo $PATH | grep "$HOME/bin" &> /dev/null; then
3838
echo 'export PATH=~/bin:$PATH' >> ~/.profile
39+
40+
if echo $SHELL | grep "zsh" &> /dev/null; then
41+
echo 'export PATH=~/bin:$PATH' >> ~/.zshrc
42+
fi
3943
fi
4044

4145
echo -e "\033[1;32mAll successful, please log in again or source ~/.profile manually\033[0m"

0 commit comments

Comments
 (0)