From: Bart Schaefer <schaefer@brasslantern.com>
To: zsh workers <zsh-workers@zsh.org>
Subject: Re: [PATCH] Quote components before using it is pattern
Date: Sat, 21 Aug 2010 09:54:10 -0700 [thread overview]
Message-ID: <100821095410.ZM31747@torch.brasslantern.com> (raw)
In-Reply-To: <AANLkTimzOEX5ZvUorwx2UsvT2u+YjDfER6Gt6E1CZMvL@mail.gmail.com>
On Aug 21, 2:46pm, Mikael Magnusson wrote:
} Subject: Re: [PATCH] Quote components before using it is pattern
}
} On 14 October 2008 17:01, Jorg Sommer <joerg@alea.gnuu.de> wrote:
Wow, digging back into history a bit here ...
} >> A component might contain a character active in patterns, like * or ().
} >>
} >> The characters in the temporary variable tmp1 must be quote, before the
} >> pattern is build with them.
}
} This patch sort of breaks completing when the first segment has spaces
} for me.
As has come up elsewhere, the problem is that ${(q)...} is a bit too
aggressive for the purpose to which it is being put. We need to quote
pattern characters in tmp1, but not other characters like spaces.
There's a rather ugly hunk of code in _path_files that does something
like this (see the comment "Explanation of substitution: ...") but
unfortunately I don't have time this morning to try to adapt it for
_multi_parts.
next prev parent reply other threads:[~2010-08-21 16:54 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-13 23:01 Jörg Sommer
2008-10-14 15:01 ` Jörg Sommer
2010-08-21 12:46 ` Mikael Magnusson
2010-08-21 16:54 ` Bart Schaefer [this message]
2010-08-21 17:04 ` Mikael Magnusson
2010-08-21 17:12 ` Bart Schaefer
2010-08-21 17:25 ` Mikael Magnusson
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=100821095410.ZM31747@torch.brasslantern.com \
--to=schaefer@brasslantern.com \
--cc=zsh-workers@zsh.org \
/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).