Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: Re: completing filenames containing spaces
- X-seq: zsh-workers 11776
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: PATCH: Re: completing filenames containing spaces
- Date: Tue, 6 Jun 2000 14:17:17 +0200 (MET DST)
- In-reply-to: Adam Spiers's message of Tue, 6 Jun 2000 12:24:36 +0100
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Adam Spiers wrote:
> ...
>
> I've narrowed it down to a test case:
>
> pulse% zsh -f
> pulse% autoload compinit
> pulse% compinit
> pulse% setopt globcomplete
I'm more and more of the opinion that we need some shell-code
interface to haswilds(). Sigh.
Bye
Sven
Index: Completion/Core/_path_files
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Core/_path_files,v
retrieving revision 1.18
diff -u -r1.18 _path_files
--- Completion/Core/_path_files 2000/05/31 09:38:26 1.18
+++ Completion/Core/_path_files 2000/06/06 12:16:37
@@ -184,7 +184,7 @@
[[ $compstate[insert] = (*menu|[0-9]*) || -n "$_comp_correct" ||
( -n "$compstate[pattern_match]" &&
- "${orig#\~}" != "${${orig#\~}:q}" ) ]] && menu=yes
+ "${orig#\~}" != (|*[^\\])[][*?#~^\|\<\>]* ) ]] && menu=yes
# Now let's have a closer look at the string to complete.
@@ -491,7 +491,8 @@
fi
if (( tmp4 )) ||
- [[ -n "$compstate[pattern_match]" && "$tmp2" != "${(q)tmp2}" ]]; then
+ [[ -n "$compstate[pattern_match]" &&
+ "$tmp2" = (|*[^\\])[][*?#~^\|\<\>]* ]]; then
# It is. For menucompletion we now add the possible completions
# for this component with the unambigous prefix we have built
# and the rest of the string from the line as the suffix.
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author