summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/check_for_upgrade.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/check_for_upgrade.sh b/tools/check_for_upgrade.sh
index 5afd83c1e..1c897cb36 100644
--- a/tools/check_for_upgrade.sh
+++ b/tools/check_for_upgrade.sh
@@ -26,6 +26,9 @@ fi
# oh-my-zsh directory.
[[ -w "$ZSH" ]] || return 0
+# Cancel upgrade if git is unavailable on the system
+whence git >/dev/null || return 0
+
if [ -f ~/.zsh-update ]
then
. ~/.zsh-update
@@ -54,4 +57,3 @@ else
# create the zsh file
_update_zsh_update
fi
-