summaryrefslogtreecommitdiff
path: root/Completion/Zsh/Command/_unhash
diff options
context:
space:
mode:
authorAxel Beckert <abe@deuxchevaux.org>2015-05-05 23:32:59 +0200
committerAxel Beckert <abe@deuxchevaux.org>2015-05-05 23:58:59 +0200
commitdb38e167634b6c2217eec3a5aafc37c46d9e5a8d (patch)
treedaa342d423febbd3a5a7ef97053037677fab004a /Completion/Zsh/Command/_unhash
parent01eea47617a6e06debdb4330f92ae69f92089fd2 (diff)
parent3c3c8d3d13fd4cf6c03f81ca8dc18a1efd561728 (diff)
downloadzsh-db38e167634b6c2217eec3a5aafc37c46d9e5a8d.tar.gz
zsh-db38e167634b6c2217eec3a5aafc37c46d9e5a8d.zip
Merge branch 'upstream' into debian
Diffstat (limited to 'Completion/Zsh/Command/_unhash')
-rw-r--r--Completion/Zsh/Command/_unhash11
1 files changed, 3 insertions, 8 deletions
diff --git a/Completion/Zsh/Command/_unhash b/Completion/Zsh/Command/_unhash
index c05c27ea3..ff0c03f49 100644
--- a/Completion/Zsh/Command/_unhash
+++ b/Completion/Zsh/Command/_unhash
@@ -1,14 +1,9 @@
#compdef unhash
-local expl state line curcontext="$curcontext"
-
-_arguments -C -s -S \
- '(-a -f -s *)-d[remove named directories]:*:named directory:->nameddir' \
+_arguments -s -S \
+ '(-a -f -s *)-d[remove named directories]:*:named directory:compadd -k nameddirs' \
'(-d -f -s *)-a[remove aliases]:*:alias:_aliases' \
'(-a -d -f *)-s[remove suffix aliases]:*:suffix alias:_aliases -s s' \
'(-d -a -s *)-f[remove functions]:*:shell function:_functions' \
'-m[treat arguments as patterns]' \
- '(-a -d -f -m)*:command: _command_names -e' && return 0
-
-[[ "$state" = nameddir ]] &&
- _wanted named-directories expl 'named directory' compadd -k nameddirs
+ '(-a -d -f -m)*:command: _command_names -e'