From: Peter Stephenson <pws@csr.com>
To: zsh-workers@sunsite.dk (Zsh hackers list)
Subject: Re: Space-expansion problem in dev-8
Date: Thu, 01 Feb 2001 17:57:19 +0000 [thread overview]
Message-ID: <Tc0a8890c5177930f27@mailsweeper01.cambridgesiliconradio.com> (raw)
In-Reply-To: Your message of "Thu, 01 Feb 2001 09:41:14 PST." <Pine.LNX.4.21.0102010930180.8191-100000@phong.blorf.net>
> If a filename contains spaces (or other escapable characters) and you
> expand it via wild-carding, the spaces are not escaped.
The fix is probably something like the following, but Sven may have better
ideas. This is leaving my cursor at the end of the word for some reason.
Probably _expand was written before ${(q)...} existed.
Index: Completion/Core/_expand
===================================================================
RCS file: /cvsroot/zsh/zsh/Completion/Core/_expand,v
retrieving revision 1.33
diff -u -r1.33 _expand
--- Completion/Core/_expand 2000/10/11 12:19:24 1.33
+++ Completion/Core/_expand 2001/02/01 17:46:47
@@ -68,7 +68,7 @@
# Now try globbing.
[[ "$force" = *g* ]] || zstyle -T ":completion:${curcontext}:" glob &&
- eval 'exp=( ${~exp} ); exp=( ${exp//(#b)([][()|*?^#~<>\\=])/\\${match[1]}} )' 2>/dev/null
+ eval 'exp=( ${~exp} ); exp=( ${(q)exp} )' 2>/dev/null
# If we don't have any expansions or only one and that is the same
# as the original string, we let other completers run.
--
Peter Stephenson <pws@csr.com> Software Engineer
Cambridge Silicon Radio, Unit 300, Science Park, Milton Road,
Cambridge, CB4 0XL, UK Tel: +44 (0)1223 392070
next prev parent reply other threads:[~2001-02-01 17:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-02-01 17:41 Wayne Davison
2001-02-01 17:57 ` Peter Stephenson [this message]
2001-02-02 8:21 Sven Wischnowsky
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Tc0a8890c5177930f27@mailsweeper01.cambridgesiliconradio.com \
--to=pws@csr.com \
--cc=zsh-workers@sunsite.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).