help / color / mirror / code / Atom feed
From: Bart Schaefer <schaefer@brasslantern.com>
To: Philippe Proulx <eeppeliteloop@gmail.com>
Cc: Daniel Shahaf <d.s@daniel.shahaf.name>, Zsh Users <zsh-users@zsh.org>
Subject: Re: How to complete with _arguments() depending on an option and within a loop
Date: Wed, 12 May 2021 08:11:32 -0700	[thread overview]
Message-ID: <CAH+w=7aZCWOXij65=TDcuV1hcus8-gq-zJcEfP7XT0gVRW-7sg@mail.gmail.com> (raw)
In-Reply-To: <CAB4xu_09nbsdpRviaB_+wcEmnccUqXL1r2MYVSmv_yP80Ukhqg@mail.gmail.com>

On Wed, May 12, 2021 at 6:44 AM Philippe Proulx <eeppeliteloop@gmail.com> wrote:
>     $ beep --device --new <tab>
> Zsh offers `--device` again, because the completion script "saw" the
> `--new` word, without taking any parsing into account.

What everybody seems to forget about completion is that it's supposed
to save the user typing time, not save the user from thinkos.  If the
user is uncomprehending enough to select --device twice just because
completion offered it, it's not our job to come to the rescue.

  reply	other threads:[~2021-05-12 15:13 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-10 17:30 Philippe Proulx
2021-05-11 14:12 ` Daniel Shahaf
2021-05-12 13:44   ` Philippe Proulx
2021-05-12 15:11     ` Bart Schaefer [this message]
2021-05-12 15:14       ` Philippe Proulx
2021-05-12 15:50         ` Bart Schaefer
2021-05-12 16:14           ` Ray Andrews

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAH+w=7aZCWOXij65=TDcuV1hcus8-gq-zJcEfP7XT0gVRW-7sg@mail.gmail.com' \
    --to=schaefer@brasslantern.com \
    --cc=d.s@daniel.shahaf.name \
    --cc=eeppeliteloop@gmail.com \
    --cc=zsh-users@zsh.org \


* 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


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).