zsh: Don't autoload completion and hidden files

Ignore files that are hidden and functions that follow the naming
convention of completion functions.
This commit is contained in:
2020-09-27 18:39:43 +02:00
parent 9ae3de7d64
commit 6158900925

View File

@@ -125,7 +125,7 @@ autoload edit-command-line; zle -N edit-command-line
autoload run-help run-help-git zmv
if [ -d "$ZDOTDIR/autoload" ]; then
fpath=("$ZDOTDIR/autoload" $fpath)
autoload -Uz -- "" "${fpath[1]}"/*(.xN:t)
autoload -Uz -- "" "${fpath[1]}"/[^_.]*(.xN:t)
fi
! command -v direnv >/dev/null 2>&1 || eval "$(direnv hook zsh)"
# stderred