* PATCH: Re: Problem completing variables that contain spaces
@ 2001-03-29 8:58 Sven Wischnowsky
0 siblings, 0 replies; only message in thread
From: Sven Wischnowsky @ 2001-03-29 8:58 UTC (permalink / raw)
To: zsh-workers
Wayne Davison wrote:
> ...
>
> The critical bit appears to be:
>
> zstyle ':completion:*' completer _expand _complete
> zstyle ':completion:*:expand:*' suffix false
Ah, yes, now it could reproduce it. There was a missing (q) flag when
comparing the prefix of the expansion generated so far with the
expansion of the prefix alone.
> [...] However, with this set:
>
> zstyle ':completion:*:expand:*' keep-prefix true
>
> the behavior of "suffix false" works exactly like "suffix true". [...]
But that's correct, isn't it? Judging from the documentation (and the
code and from what I intended... ;-).
Bye
Sven
Index: Completion/Core/_expand
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Core/_expand,v
retrieving revision 1.35
diff -u -r1.35 _expand
--- Completion/Core/_expand 2001/03/11 19:30:42 1.35
+++ Completion/Core/_expand 2001/03/29 08:58:19
@@ -93,7 +93,7 @@
eval 'epre=( ${(e)~${word%%/*}} )' 2>/dev/null
if [[ -n "$epre" && $#epre -eq 1 ]]; then
opre="${word%%/*}"
- pre="$epre[1]"
+ pre="${(q)epre[1]}"
[[ "$tmp" != changed || $#exp -gt 1 ||
"${opre}${exp[1]#${pre}}" != "$word" ]] && exp=( ${opre}${^exp#${pre}} )
fi
--
Sven Wischnowsky wischnow@informatik.hu-berlin.de
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2001-03-29 8:58 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-03-29 8:58 PATCH: Re: Problem completing variables that contain spaces Sven Wischnowsky
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).