summaryrefslogtreecommitdiff
path: root/tools/install.sh
diff options
context:
space:
mode:
Diffstat (limited to 'tools/install.sh')
-rwxr-xr-xtools/install.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/install.sh b/tools/install.sh
index 3f0e468fe..15c7b7703 100755
--- a/tools/install.sh
+++ b/tools/install.sh
@@ -184,6 +184,13 @@ setup_shell() {
fi
fi
+ # We're going to change the default shell, so back up the current one
+ if [ -n $SHELL ]; then
+ echo $SHELL > ~/.shell.pre-oh-my-zsh
+ else
+ grep "^$USER:" /etc/passwd | awk -F: '{print $7}' > ~/.shell.pre-oh-my-zsh
+ fi
+
# Actually change the default shell to zsh
if ! chsh -s "$zsh"; then
error "chsh command unsuccessful. Change your default shell manually."