diff options
author | Robby Russell <robby@planetargon.com> | 2013-12-02 23:37:49 -0800 |
---|---|---|
committer | Robby Russell <robby@planetargon.com> | 2013-12-02 23:37:49 -0800 |
commit | f574849c0a1da879f5e23cea21ef76f6e10e0830 (patch) | |
tree | ad0fe51fc0ff4048646a0600a5eb23c4b6146022 | |
parent | 533e31f2cc232c6c58529be9ce634979db9dde31 (diff) | |
parent | d4a9467f89115c1e60b51d8c068ec4e5e1c5b195 (diff) | |
download | zsh-f574849c0a1da879f5e23cea21ef76f6e10e0830.tar.gz zsh-f574849c0a1da879f5e23cea21ef76f6e10e0830.tar.bz2 zsh-f574849c0a1da879f5e23cea21ef76f6e10e0830.zip |
Merge pull request #1927 from dongweiming/modify
Modify determine the oh-my-zsh installed in non-default path of the installed
-rwxr-xr-x | tools/install.sh | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/install.sh b/tools/install.sh index a2bd5665a..5af038fd9 100755 --- a/tools/install.sh +++ b/tools/install.sh @@ -1,6 +1,11 @@ -if [ -d ~/.oh-my-zsh ] +ZSH=`/usr/bin/env|grep 'ZSH='|cut -d '=' -f 2` +if [ -d "$ZSH" ] then - echo "\033[0;33mYou already have Oh My Zsh installed.\033[0m You'll need to remove ~/.oh-my-zsh if you want to install" + echo "\033[0;33mYou already have Oh My Zsh installed.\033[0m You'll need to remove $ZSH if you want to install" + exit +elif [ -d ~/.oh-my-zsh ] +then + echo "\033[0;33mYou already have One Oh My Zsh Directory.\033[0m You'll need to remove ~/.oh-my-zsh if you want to clone" exit fi |