From f844c87a4d676bcc8ad7ac24b5132d7aa5ccfeca Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Wed, 1 Dec 1999 15:29:41 +0000 Subject: zsh-workers/8840 --- Completion/Core/_wanted | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'Completion/Core/_wanted') diff --git a/Completion/Core/_wanted b/Completion/Core/_wanted index 7baa3e724..f95d74451 100644 --- a/Completion/Core/_wanted +++ b/Completion/Core/_wanted @@ -1,6 +1,6 @@ #autoload -local targs +local targs tag if [[ "$1" = -C?* ]]; then targs=( -C "${1[3,-1]}" ) @@ -12,10 +12,14 @@ else targs=() fi -[[ "$1" = -(|-) ]] && shift +if [[ "$1" = -[VJ]* ]]; then + tag="$2" +else + tag="$1" +fi if [[ $# -gt 1 ]]; then - _tags "$targs[@]" "$1" && _description "${(@)argv[2,-1]}" + _tags "$targs[@]" "$tag" && _description "$@" else - _tags "$targs[@]" "$1" + _tags "$targs[@]" "$tag" fi -- cgit 1.4.1