about summary refs log tree commit diff
path: root/Completion/Builtins/_zmodload
blob: 4b0e91442ba977b053f8456fdebfad79e2f95ad5 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
#compdef zmodload

local fl="$words[2]"

if [[ "$fl" = -*(a*u|u*a)* || "$fl" = -*a* && CURRENT -ge 4 ]]; then
  compgen -B
elif [[ "$fl" = -*u* ]]; then
  compgen -s '$(zmodload)'
else
  compgen -s '${^module_path}/*(N:t:r)'
fi