From: Wayne Davison <wayned@users.sourceforge.net>
To: Mikael Magnusson <mikachu@gmail.com>
Cc: zsh-workers@sunsite.dk
Subject: Re: Bug in { completion's comma removal
Date: Fri, 6 Jan 2006 12:36:55 -0800 [thread overview]
Message-ID: <20060106203655.GF10111@dot.blorf.net> (raw)
In-Reply-To: <237967ef0601061207h7802915dm580a12122a971242@mail.gmail.com>
On Fri, Jan 06, 2006 at 09:07:19PM +0100, Mikael Magnusson wrote:
> While we're talking about {}, it also doesn't work so well on
> filenames with spaces
I haven't seen any problems with spaces as long as you put a backslash
in front of each one (which is what the completion of a filename with
spaces will automatically add). This is to be expected because a
command-line of "f{oo bar,oo-baz}" (without the quotes) is really two
args (neither one valid in syntax), but adding a backslash before the
space makes it a single arg that will expand into two, "foo\ bar" and
"foo-baz".
> and there's no way (that i've figured out) to escape a comma inside
> the braces.
Yes, this is a problem when completing and expanding in zle. It does
appear to work fine in the shell itself:
% echo ba{r\,1,z\,2}
bar,1 baz,2
However, when completing a filename with a comma inside an open {, zsh
does not add a backslash before the comma, and it strips any existing
backslash before a comma (e.g. pressing <TAB> on the above term would
incorrectly expand the line into "echo bar ba1 baz ba2").
..wayne..
next prev parent reply other threads:[~2006-01-06 20:37 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-06 18:00 Wayne Davison
2006-01-06 20:07 ` Mikael Magnusson
2006-01-06 20:36 ` Wayne Davison [this message]
2006-01-07 4:50 ` Mikael Magnusson
2006-02-11 4:00 ` Wayne Davison
2006-02-13 10:51 ` Peter Stephenson
2006-02-09 22:17 ` Wayne Davison
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=20060106203655.GF10111@dot.blorf.net \
--to=wayned@users.sourceforge.net \
--cc=mikachu@gmail.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).