From: "Lawrence Velázquez" <vq@larryv.me>
To: zsh-workers@zsh.org
Subject: Re: Proposal: Let compinit make standard widgets with _generic instead of _main_complete
Date: Sat, 03 Apr 2021 15:37:51 -0400 [thread overview]
Message-ID: <dc8150e9-f42a-4502-828d-1ac8cbf26940@www.fastmail.com> (raw)
In-Reply-To: <CAHLkEDuo=8MbjYWOmQM5d4uLOzo+BC6XTy=S14-BfeBPMZjysw@mail.gmail.com>
On Mon, Mar 22, 2021, at 3:16 AM, Marlon Richert wrote:
> On Mon, Mar 22, 2021 at 3:46 AM Bart Schaefer <schaefer@brasslantern.com> wrote:
> > It refers to the completion results being generic, not to the context ... but of course the style can be called anything, it's more the functionality that's in question.
>
> On Sun, Mar 21, 2021 at 1:53 AM Bart Schaefer <schaefer@brasslantern.com> wrote:
> > +if [[ "${curcontext:-:::}" == ::: ]] &&
> > + zstyle -t ":completion:::::" generic-widgets "$WIDGET"
> > +then
> > + _generic "$@"
> > + return
> > +fi
>
> This feels like a rather roundabout solution. _generic itself already
> checks whether $curcontext is set and then calls _main_complete. Why
> not just do the straightforward thing, and let the widget call
> _generic directly, which in turn will call _main_complete anyway?
Anything else on this?
vq
next prev parent reply other threads:[~2021-04-03 19:38 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-19 22:23 Marlon Richert
2021-03-20 18:09 ` Bart Schaefer
2021-03-20 23:52 ` Bart Schaefer
2021-03-21 15:19 ` Marlon Richert
2021-03-22 1:46 ` Bart Schaefer
2021-03-22 7:16 ` Marlon Richert
2021-04-03 19:37 ` Lawrence Velázquez [this message]
2021-04-04 18:35 ` Bart Schaefer
2021-04-04 19:31 ` Bart Schaefer
2021-04-09 19:11 ` Oliver Kiddle
2021-04-09 19:35 ` Bart Schaefer
2021-05-09 20:51 ` Lawrence Velázquez
2021-05-10 17:11 ` Bart Schaefer
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=dc8150e9-f42a-4502-828d-1ac8cbf26940@www.fastmail.com \
--to=vq@larryv.me \
--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).