diff --git a/bash/direnv-hook b/bash/direnv-hook index 38a118b..5960ace 100644 --- a/bash/direnv-hook +++ b/bash/direnv-hook @@ -4,7 +4,7 @@ _direnv_hook() { eval "$(direnv export bash)"; }; -if type direnv > /dev/null; then +if [[ -x $(command -v direnv) ]]; then if ! [[ "$PROMPT_COMMAND" =~ _direnv_hook ]]; then PROMPT_COMMAND="_direnv_hook;$PROMPT_COMMAND"; fi