From cedfce5a8fcdd496e8ae4ba12ba5cc8b21e5eb3c Mon Sep 17 00:00:00 2001 From: Raoul Snyman Date: Tue, 11 Jul 2023 16:31:04 -0700 Subject: [PATCH] Only change shell if it is not already zsh --- setup.sh | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/setup.sh b/setup.sh index cb9ecbd..74667d1 100644 --- a/setup.sh +++ b/setup.sh @@ -79,7 +79,9 @@ function setup_zsh() { zsh -c 'setopt EXTENDED_GLOB; for rcfile in "${ZDOTDIR:-$HOME}"/.zprezto/runcoms/^README.md(.N); do ln -s "$rcfile" "${ZDOTDIR:-$HOME}/.${rcfile:t}"; done' cd $HOME patch -p0 < $DIR/zsh/prezto.diff - chsh -s /bin/zsh + if [[ `getent passwd $USER | awk -F: '{print $NF}'` != "/bin/zsh" ]]; then + chsh -s /bin/zsh + fi } function setup_topydo() {