plugins/direnv: use _command_exists

This commit is contained in:
John D Pell
2021-09-19 21:48:13 -07:00
parent b038ea5869
commit c98424308a
2 changed files with 5 additions and 1 deletions

View File

@@ -1,4 +1,7 @@
# shellcheck shell=bash
cite about-plugin
about-plugin 'load direnv, if you are using it: https://direnv.net/'
[ -x "$(which direnv)" ] && eval "$(direnv hook bash)"
if _command_exists direnv; then
eval "$(direnv hook bash)"
fi