Limit find to maxdepth 1 when searching zshlib

This commit is contained in:
Rezart Qelibari
2022-01-28 17:46:17 +01:00
parent 60c1356158
commit eee681bae9

View File

@@ -11,7 +11,7 @@ function ensureDocopts() {
function autoloadZShLib() {
FPATH="`pwd`/zshlib:${FPATH}"
local funcNames=("${(@f)$(find ./zshlib -type f -perm +u=x | awk -F/ '{ print $NF }')}")
local funcNames=("${(@f)$(find ./zshlib -type f -perm +u=x -maxdepth 1 | awk -F/ '{ print $NF }')}")
autoload -Uz "${funcNames[@]}"
}