From: Oliver Kiddle <opk@u.genie.co.uk>
To: zsh-workers@sunsite.dk
Subject: Re: problem with _arguments exclusion lists
Date: Mon, 23 Apr 2001 09:59:53 +0100 [thread overview]
Message-ID: <3AE3EF09.C25C8DF8@u.genie.co.uk> (raw)
In-Reply-To: <200104200831.KAA14053@beta.informatik.hu-berlin.de>
Sven Wischnowsky wrote:
>
> 1) Add an option to _arguments, that says that it should always try to
> complete options after options specified with `-x-:...' or `-x+:...'.
> 2) Also, make it try completing options in those places even if the new
> _arguments-option is not given but the action for the argument
> returns non-null.
I'm happy with that.
> The `returns non-null' is, of course, problematic again if the option-
> argument has to be completed with a `->state' action. But I think if
That's a bit of a pity.
> And add a small utility function that can be put into an argument-
> action and tests if the string typed so far matches some pattern.
Agreed.
> For simplicity I would make it use the description given in the
> _arguments-spec.
I'll be interested to see how you do that. I think the function will
have wider uses than just from _arguments such as from _alternative so
it would be good if it can cope with that.
> And if a simple pattern match is enough for most
> cases, this makes it sound as if we should just add a new action-
> syntax, avoiding the need for an extra function consisting of only
I prefer the extra two-line function to extending _arguments' action
spec syntax. The function is a more general method which may be more
widely useful and it keeps things more in zsh shell syntax than in
_arguments syntax. Also, I can't see that guards on _arguments specs
would be particularly useful when matches are generated.
> Ok, would this be enough for now? Later we can, as suggested by Oliver,
> add a way to change the behaviour on a per-option basis, using the
> option from 1) as the default. If we ever meet a command that needs
> that much control.
Agreed.
Oliver
next prev parent reply other threads:[~2001-04-23 9:00 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-04-12 14:32 Oliver Kiddle
2001-04-17 9:50 ` Sven Wischnowsky
2001-04-17 10:44 ` Oliver Kiddle
2001-04-17 11:28 ` Sven Wischnowsky
2001-04-17 13:55 ` Oliver Kiddle
2001-04-17 14:10 ` Sven Wischnowsky
2001-04-19 14:01 ` Oliver Kiddle
2001-04-20 8:31 ` Sven Wischnowsky
2001-04-23 8:59 ` Oliver Kiddle [this message]
2001-04-24 10:00 ` Sven Wischnowsky
2001-04-26 11:00 ` Oliver Kiddle
2001-04-26 12:10 ` Sven Wischnowsky
2001-04-25 7:10 ` Sven Wischnowsky
2001-04-26 13:55 Oliver Kiddle
2001-04-26 14:35 ` Sven Wischnowsky
2001-05-04 16:20 ` Oliver Kiddle
2001-05-07 11:10 ` Sven Wischnowsky
2001-05-08 11:45 ` Oliver Kiddle
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=3AE3EF09.C25C8DF8@u.genie.co.uk \
--to=opk@u.genie.co.uk \
--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).