From 6f8986d370a7b4d799cab40c5ac3a3d937b9faeb Mon Sep 17 00:00:00 2001 From: Bart Schaefer Date: Mon, 3 Jul 2000 17:45:46 +0000 Subject: 12148: Don't merge display-ordering glob flags into the parens of $(...). --- ChangeLog | 6 ++++++ Completion/Core/_path_files | 12 ++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 41e1d5326..919c914ce 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2000-07-03 Bart Schaefer + + * 12148: Completion/Core/_path_files: Followup to 12133 as + suggested by Sven in 12137: Don't merge display-ordering glob + flags into the parens in $(...) expressions. + 2000-07-03 Peter Stephenson * 12146: Doc/Makefile.in: reintroduce mysteriously disappeared diff --git a/Completion/Core/_path_files b/Completion/Core/_path_files index df7f50d8a..48e9dd299 100644 --- a/Completion/Core/_path_files +++ b/Completion/Core/_path_files @@ -117,9 +117,9 @@ if zstyle -s ":completion:${curcontext}:files" file-sort tmp1; then tmp2=() for tmp1 in "$pats[@]"; do - if [[ "$tmp1" = (#b)(?*)(\(\([^\|~]##\)\)) ]]; then + if [[ "$tmp1" = (#b)(*[^\$])(\(\([^\|~]##\)\)) ]]; then tmp2=( "$tmp2[@]" "${match[1]}((${sort}${match[2][3,-1]}" ) - elif [[ "$tmp1" = (#b)(?*)(\([^\|~]##\)) ]]; then + elif [[ "$tmp1" = (#b)(*[^\$])(\([^\|~]##\)) ]]; then tmp2=( "$tmp2[@]" "${match[1]}(${sort}${match[2][2,-1]}" ) else tmp2=( "$tmp2[@]" "${tmp1}(${sort})" ) @@ -150,8 +150,8 @@ zstyle -a ":completion:${curcontext}:files" fake fake zstyle -s ":completion:${curcontext}:files" ignore-parents ignpar if [[ -n "$compstate[pattern_match]" && - ( ( -z "$SUFFIX" && "$PREFIX" = *\([^\|\~]##\) ) || - "$SUFFIX" = *\([^\|\~]##\) ) ]]; then + ( ( -z "$SUFFIX" && "$PREFIX" = (|*[^\$])\([^\|\~]##\) ) || + "$SUFFIX" = (|*[^\$])\([^\|\~]##\) ) ]]; then # Copy all glob qualifiers from the line to # the patterns used when generating matches if [[ "$SUFFIX" = *\([^\|\~]##\) ]]; then @@ -163,9 +163,9 @@ if [[ -n "$compstate[pattern_match]" && fi tmp2=() for tmp1 in "$pats[@]"; do - if [[ "$tmp1" = (#b)(?*)(\(\([^\|~]##\)\)) ]]; then + if [[ "$tmp1" = (#b)(*[^\$])(\(\([^\|~]##\)\)) ]]; then tmp2=( "$tmp2[@]" "${match[1]}((${tmp3}${match[2][3,-1]}" ) - elif [[ "$tmp1" = (#b)(?*)(\([^\|~]##\)) ]]; then + elif [[ "$tmp1" = (#b)(*[^\$])(\([^\|~]##\)) ]]; then tmp2=( "$tmp2[@]" "${match[1]}(${tmp3}${match[2][2,-1]}" ) else tmp2=( "$tmp2[@]" "${tmp1}(${tmp3})" ) -- cgit 1.4.1