c113e88c454cf759078f06c95f4b35db90acb9d7
- Author
- Tim Taylor <tim@tool-man.org>
- Committer
- Tim Taylor <tim@tool-man.org>
- Date
Message
Fix auto upgrade failure from non-exported ZSH env var
Fixes #549. Specify ZSH=$ZSH explicitly when invoking
the auto update scripts.
Diff
1diff --git a/oh-my-zsh.sh b/oh-my-zsh.sh
2index c4522491bc083f1cade6207432a4f4e62c6d009c..f7776281579ee2551e7102f20cafbace564161fd 100644
3--- a/oh-my-zsh.sh
4+++ b/oh-my-zsh.sh
5@@ -1,7 +1,7 @@
6 # Check for updates on initial load...
7 if [ "$DISABLE_AUTO_UPDATE" != "true" ]
8 then
9- /usr/bin/env zsh $ZSH/tools/check_for_upgrade.sh
10+ /usr/bin/env ZSH=$ZSH zsh $ZSH/tools/check_for_upgrade.sh
11 fi
12
13 # Initializes Oh My Zsh
14diff --git a/tools/check_for_upgrade.sh b/tools/check_for_upgrade.sh
15index e1e4eb99f0a6c954ad09cf6faf1c4f0f9b342888..aeaa0e415f496a7b0d895efe582833bb9f87dc2d 100644
16--- a/tools/check_for_upgrade.sh
17+++ b/tools/check_for_upgrade.sh
18@@ -24,7 +24,7 @@ then
19 read line
20 if [ "$line" = Y ] || [ "$line" = y ]
21 then
22- /bin/sh $ZSH/tools/upgrade.sh
23+ /usr/bin/env ZSH=$ZSH /bin/sh $ZSH/tools/upgrade.sh
24 # update the zsh file
25 _update_zsh_update
26 fi