Revert "Change plugins to not do anything if tool isn't available" master
authorAlexander Barton <alex@barton.de>
Mon, 8 Jun 2015 13:21:10 +0000 (15:21 +0200)
committerAlexander Barton <alex@barton.de>
Mon, 8 Jun 2015 13:21:10 +0000 (15:21 +0200)
Probably not such a good idea: the OhMyZsh plugins don't follow this
style but echo warning/error messages. So please adjust your ~/.zshrc
to (conditionally) only list desired/available plugins.

This reverts commit 9ea48355673a75f1d63320be20a231837a816781.

plugins/5_dev_env/5_dev_env.plugin.zsh
plugins/boot2docker/boot2docker.plugin.zsh
plugins/keychain/keychain.plugin.zsh
plugins/thefuck/thefuck.plugin.zsh

index 9e4cd26f62c606be52e7903796c5d231d55eaf64..2977ff87e2ead1d09d2e7e48382ceb86a19f963a 100644 (file)
@@ -15,14 +15,10 @@ done
 unset ssh_wrapper
 
 # pip
-if (( $+commands[pip] )); then
-       export PIP_REQUIRE_VIRTUALENV="true"
-fi
+export PIP_REQUIRE_VIRTUALENV="true"
 
 # virtualenv[wrapper]
-if (( $+commands[virtualenv] )); then
-       export WORKON_HOME="$XDG_CACHE_HOME/virtualenvs"
-       [ -d "$LOCAL_HOME/Develop" ] \
-               && export PROJECT_HOME="$LOCAL_HOME/Develop" \
-               || export PROJECT_HOME="$HOME/Develop"
-fi
+export WORKON_HOME="$XDG_CACHE_HOME/virtualenvs"
+[ -d "$LOCAL_HOME/Develop" ] \
+        && export PROJECT_HOME="$LOCAL_HOME/Develop" \
+        || export PROJECT_HOME="$HOME/Develop"
index 8a63173ea4d893769fbfce2acb185391e72f790d..9813acdb487943a97b10475169cf3d531f3fb281 100644 (file)
@@ -1,10 +1,8 @@
 # boot2docker.plugin.zsh
 
-if (( $+commands[boot2docker] )); then
-       boot2docker status | fgrep "running" >/dev/null
-       if [ $? -eq 0 ]; then
-               # boot2docker VM is running
-               eval `boot2docker shellinit 2>/dev/null`
-               DOCKER_HOST_IPA=${(z)${(s.:.)DOCKER_HOST#tcp://}[1]}
-       fi
+boot2docker status | fgrep "running" >/dev/null
+if [ $? -eq 0 ]; then
+       # boot2docker VM is running
+       eval `boot2docker shellinit 2>/dev/null`
+       DOCKER_HOST_IPA=${(z)${(s.:.)DOCKER_HOST#tcp://}[1]}
 fi
index e01f9ae6cf0881f4aae0ef6fb36ec9ec05f29a35..c1c6fbbc20a104e080340ce03e46eaaa53a2e9c5 100644 (file)
@@ -1,5 +1,3 @@
 # keychain.plugin.zsh
 
-if (( $+commands[keychain] )); then
-       eval $(keychain --agents ssh --eval --quick --quiet)
-fi
+eval $(keychain --agents ssh --eval --quick --quiet)
index 754d342168bb94615b0d5f50fa717736c30150ba..4042544c7173256d1ec4c3e02f84621d6aa6812a 100644 (file)
@@ -1,5 +1,3 @@
 # thefuck.plugin.zsh
 
-if (( $+commands[thefuck] )); then
-       alias fuck='eval $(thefuck $(fc -ln -1 | tail -n 1)); fc -R'
-fi
+alias fuck='eval $(thefuck $(fc -ln -1 | tail -n 1)); fc -R'