From: Peng Li Date: Sun, 22 Jan 2017 07:05:59 +0000 (+0800) Subject: fix installation issue, check command before run it X-Git-Url: http://47.100.26.94:8080/?a=commitdiff_plain;ds=inline;h=49336e7450df90a81a33f0934f539afe2427c70e;p=dotfiles.git fix installation issue, check command before run it --- diff --git a/zsh/zshrc b/zsh/zshrc index d8f77ff..90b0c45 100644 --- a/zsh/zshrc +++ b/zsh/zshrc @@ -208,7 +208,10 @@ export ZSHHOME="$HOME/.zsh" #` git log --oneline --abbrev-commit --all --graph --decorate --color ` -[[ -s `brew --prefix`/etc/autojump.sh ]] && . `brew --prefix`/etc/autojump.sh +`which brew` &> /dev/null +if [ $? -eq 0 ]; then + [[ -s `brew --prefix`/etc/autojump.sh ]] && . `brew --prefix`/etc/autojump.sh +fi alias emacs='TERM=xterm-256color emacs -nw'