zsh-workers
 help / color / mirror / code / Atom feed
From: Mikael Magnusson <mikachu@gmail.com>
To: Marlon Richert <marlon.richert@gmail.com>
Cc: Bart Schaefer <schaefer@brasslantern.com>,
	Zsh hackers list <zsh-workers@zsh.org>
Subject: Re: Why does {..} expansion using 'bindkey' quoting, but {,} and BRACE_CCL don't quote at all?
Date: Sun, 8 Aug 2021 02:09:04 +0200	[thread overview]
Message-ID: <CAHYJk3Q8rqn77_DvqFNnAbCq8i9Yjz5-dTm-9JQuyNgcyfWsdQ@mail.gmail.com> (raw)
In-Reply-To: <CAHLkEDu7uOVDkvg8qgtsv9fE54OLhcDiQ7GpvL=cemots1Suyw@mail.gmail.com>

On 8/7/21, Marlon Richert <marlon.richert@gmail.com> wrote:
> On Fri, Aug 6, 2021 at 3:55 AM Mikael Magnusson <mikachu@gmail.com> wrote:
>>
>> On 8/6/21, Bart Schaefer <schaefer@brasslantern.com> wrote:
>> > On Wed, Aug 4, 2021 at 11:18 PM Marlon Richert
>> > <marlon.richert@gmail.com>
>> > wrote:
>> >>
>> >> I just wish {a..z} didn't use quoting at all. :)
>> >
>> > Re-reading the doc for this, {a..z} is guaranteed to produce PRINTABLE
>> > output, which is not true of the other variations of brace expansion.
>>
>> If you want to expand these printable representations to the actual
>> codepoints, you can use (g:ce:) .
>
> Thanks! I had been looking through
> https://zsh.sourceforge.io/Doc/Release/Expansion.html for anything
> mentioning `bindkey`, but couldn't find any. :)
>
>> With the c option, sequences like ‘^X’ are also processed.
>
> That could be made more "grep-able".
>
> In general, I think that page could really use a "reverse" index.
> Listing parameter flags by letter only doesn't really help in finding
> anything. Believe me, I've tried.

It is indeed always useful when the manpage happens to mention the
exact thing you're looking for, but if it did this in all places and
for everything everyone was looking for, it would be quite a bit
longer :). The documentation for the print builtin also doesn't
mention bindkey, which is why I didn't mention it in the documentation
for g::. The code also doesn't reference bindkey here, fwiw:

    case 'e':
	getkeys |= GETKEY_EMACS;
	break;
    case 'o':
	getkeys |= GETKEY_OCTAL_ESC;
	break;
    case 'c':
	getkeys |= GETKEY_CTRL;
	break;

(although GETKEYS_BINDKEY used presumably for bindkey, is defined as
the combination of exactly those three flags).

-- 
Mikael Magnusson


  reply	other threads:[~2021-08-08  0:21 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-04  7:04 Marlon Richert
2021-08-04 15:52 ` Bart Schaefer
2021-08-05  6:17   ` Marlon Richert
2021-08-05 23:36     ` Bart Schaefer
2021-08-06  0:55       ` Mikael Magnusson
2021-08-06  3:08         ` Bart Schaefer
2021-08-07 19:35         ` Marlon Richert
2021-08-08  0:09           ` Mikael Magnusson [this message]
2021-08-10 19:21             ` Marlon Richert

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=CAHYJk3Q8rqn77_DvqFNnAbCq8i9Yjz5-dTm-9JQuyNgcyfWsdQ@mail.gmail.com \
    --to=mikachu@gmail.com \
    --cc=marlon.richert@gmail.com \
    --cc=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).