diff options
author | Tanaka Akira <akr@users.sourceforge.net> | 1999-04-15 18:24:09 +0000 |
---|---|---|
committer | Tanaka Akira <akr@users.sourceforge.net> | 1999-04-15 18:24:09 +0000 |
commit | 6c1fb551ba0973c9a86e1ea479d553d66c6bf6b7 (patch) | |
tree | ec80a986c49f2da21eed83b7097f0f4e99f57e3f /Completion/Core/_sep_parts | |
parent | 640a840d2e94f0fc245ef8632050c37af23c6b94 (diff) | |
download | zsh-6c1fb551ba0973c9a86e1ea479d553d66c6bf6b7.tar.gz zsh-6c1fb551ba0973c9a86e1ea479d553d66c6bf6b7.tar.xz zsh-6c1fb551ba0973c9a86e1ea479d553d66c6bf6b7.zip |
zsh-3.1.5-pws-14 zsh-3.1.5-pws-14
Diffstat (limited to 'Completion/Core/_sep_parts')
-rw-r--r-- | Completion/Core/_sep_parts | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Completion/Core/_sep_parts b/Completion/Core/_sep_parts index c1cda2b9a..fc927163b 100644 --- a/Completion/Core/_sep_parts +++ b/Completion/Core/_sep_parts @@ -101,6 +101,8 @@ if [[ $# -le 1 || "$str" != *${2}* ]]; then _match_pattern _sep_parts test matchflags [[ -n "$_comp_correct" ]] && matchflags="$matchflags(#a$_comp_correct)" + [[ "${compstate[pattern_match]-*}" != \** ]] && test="$test:gs/*//" + test="${matchflags}${test}" testarr=( "${(@M)${(@P)arr}:#${~test}*}" ) testarr=( "${(@)testarr:#}" ) @@ -131,6 +133,9 @@ while [[ $# -gt 0 && "$str" == *${1}* ]]; do matchflags="" _match_pattern _sep_parts test matchflags [[ -n "$_comp_correct" ]] && matchflags="$matchflags(#a$_comp_correct)" + + [[ "${compstate[pattern_match]-*}" != \** ]] && test="$test:gs/*//" + test="${matchflags}${test}" # We incrementally add suffixes by appending to them the seperators @@ -163,7 +168,7 @@ done # Add the matches for each of the suffixes. for i in "$suffixes[@]"; do compadd -U "$group[@]" "$expl[@]" "$matchers[@]" "$autosuffix[@]" \ - -i "$IPREFIX" -p "$prefix" -s "$i" - "$testarr[@]" + -i "$IPREFIX" -I "$ISUFFIX" -p "$prefix" -s "$i" - "$testarr[@]" done # This sets the return value to indicate that we added matches (or not). |