diff options
author | Tanaka Akira <akr@users.sourceforge.net> | 2000-03-23 04:19:26 +0000 |
---|---|---|
committer | Tanaka Akira <akr@users.sourceforge.net> | 2000-03-23 04:19:26 +0000 |
commit | 626e2aeb1657f112feb6d03c34bb9e9f44764c75 (patch) | |
tree | 9e4a306df7b5826a796b99f0b6ffa3423ee9f5f9 /Completion/Builtins/_compdef | |
parent | 766fcd5ee2ef632cd982a1ec118dbdfde17c03a8 (diff) | |
download | zsh-626e2aeb1657f112feb6d03c34bb9e9f44764c75.tar.gz zsh-626e2aeb1657f112feb6d03c34bb9e9f44764c75.tar.xz zsh-626e2aeb1657f112feb6d03c34bb9e9f44764c75.zip |
zsh-workers/10195
Diffstat (limited to 'Completion/Builtins/_compdef')
-rw-r--r-- | Completion/Builtins/_compdef | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/Completion/Builtins/_compdef b/Completion/Builtins/_compdef index 772c6b90d..13711e865 100644 --- a/Completion/Builtins/_compdef +++ b/Completion/Builtins/_compdef @@ -16,24 +16,24 @@ _arguments -C -s \ case $state in ccom) - _wanted commands expl 'completed command' && - compadd "$expl[@]" - ${(k)_comps} + _wanted commands expl 'completed command' compadd - ${(k)_comps} ;; cfun) - if _wanted functions expl 'completion function'; then + if _wanted functions; then list=( ${^fpath:/.}/_(|*[^~])(N:t) ) - if zstyle -T ":completion:${curcontext}" prefix-hidden; then + if zstyle -T ":completion:${curcontext}:functions" prefix-hidden; then disp=( ${list[@]#_} ) - compadd "$expl[@]" -d disp - "$list[@]" + _loop functions expl 'completion function' compadd -d disp - "$list[@]" else - compadd "$expl[@]" - "$list[@]" + _loop functions expl 'completion function' compadd - "$list[@]" fi fi ;; style) - _wanted widgetstyle expl 'widget style' && - compadd complete-word delete-char-or-list expand-or-complete \ - expand-or-complete-prefix list-choices menu-complete \ - menu-expand-or-complete reverse-menu-complete + _wanted widgetstyle expl 'widget style' \ + compadd -M 'r:|-=* r:|=*' \ + complete-word delete-char-or-list expand-or-complete \ + expand-or-complete-prefix list-choices menu-complete \ + menu-expand-or-complete reverse-menu-complete ;; esac |