From 58aefcada3e25ea8fe7b8dcbf820354008f7e591 Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Mon, 17 Aug 2009 21:52:10 +0000 Subject: 27219: _files -F wasn't correctly handled --- Completion/Unix/Type/_files | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'Completion/Unix/Type') diff --git a/Completion/Unix/Type/_files b/Completion/Unix/Type/_files index 4615a60e7..1969a5feb 100644 --- a/Completion/Unix/Type/_files +++ b/Completion/Unix/Type/_files @@ -1,7 +1,7 @@ #compdef -redirect-,-default-,-default- local opts tmp glob pat pats expl tag i def descr end ign ret=1 match tried -local type sdef +local type sdef ignvars ignvar zparseopts -a opts \ '/=tmp' 'f=tmp' 'g+:-=tmp' q n 1 2 P: S: r: R: W: X+: M+: F: J+: V+: @@ -18,14 +18,18 @@ if (( $tmp[(I)-g*] )); then fi tmp=$opts[(I)-F] if (( tmp )); then - ign=( $=opts[tmp+1] ) - if [[ $ign = _comp_ignore ]]; then + ignvars=($=opts[tmp+1]) + if [[ $ignvars = _comp_ignore ]]; then ign=( $_comp_ignore ) else + ign=() + for ignvar in $ignvars; do + ign+=(${(P)ignvar}) + done opts[tmp+1]=_comp_ignore fi else - ign= + ign=() fi if zstyle -a ":completion:${curcontext}:" file-patterns tmp; then -- cgit 1.4.1