...
|
...
|
@@ -1,9 +1,9 @@
|
1
|
|
-if [ -f /usr/share/autojump/autojump.zsh ]; then # debian and ubuntu package
|
2
|
|
- . /usr/share/autojump/autojump.zsh
|
3
|
|
-elif [ -f /etc/profile.d/autojump.zsh ]; then # manual installation
|
4
|
|
- . /etc/profile.d/autojump.zsh
|
5
|
|
-elif (`command -v brew >/dev/null`); then # mac os x with brew
|
6
|
|
- if [ -f `brew --prefix`/etc/autojump ]; then
|
|
1
|
+if [ $commands[autojump] ]; then # check if autojump is installed
|
|
2
|
+ if [ -f /usr/share/autojump/autojump.zsh ]; then # debian and ubuntu package
|
|
3
|
+ . /usr/share/autojump/autojump.zsh
|
|
4
|
+ elif [ -f /etc/profile.d/autojump.zsh ]; then # manual installation
|
|
5
|
+ . /etc/profile.d/autojump.zsh
|
|
6
|
+ elif [ $commands[brew] -a -f `brew --prefix`/etc/autojump ]; then # mac os x with brew
|
7
|
7
|
. `brew --prefix`/etc/autojump
|
8
|
8
|
fi
|
9
|
9
|
fi
|