zsh/dot-config/zsh/interactive/direnv
2023-10-23 15:20:13 +11:00

9 lines
204 B
Bash

#! zsh
_direnv_hook() {
eval "$(direnv export zsh)"
}
typeset -ag precmd_functions
if (( $+commands[direnv] )) && [[ -z ${precmd_functions[(r)_direnv_hook]} ]]; then
precmd_functions+=(_direnv_hook)
fi