Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
possible bug in _arguments?
- X-seq: zsh-workers 43931
- From: Max Katsev <mkatsev@xxxxxxxxx>
- To: zsh-workers@xxxxxxx
- Subject: possible bug in _arguments?
- Date: Sun, 23 Dec 2018 14:34:54 -0800
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=l398JA2lFSuHJBBcksq/9b4q+9oYUiY3GJZt7waBIP4=; b=e2xqhEwUHPF50iqiVV+ZEQoHofrT6pNR4LTPKjzKQtx6cEg3AYbQwJYUvD14RpelXp kxHDaaDoBrrv5MMBs9BSSLMFgPCgdplT8v2yJx8GnAJfAu2gMMp3EZgFDmZ3CRSZhVbd czeg5f6Wox73HcggLQ9xJGVIURQxVM7U70KywXWRLfqRYN4+yeGyW3HXmEIQ2rYDPRdC HYer6CdXYrUY4S6PUPuH973iXEBUwZi74Dtr6DxoSmje1wa42ldS0dfEN5PeCdRRHPrP TqvQ/8wDhWQE7nVXk7KkWwE/y4aZU9TvZy1ycVHKgAj0XLaXfvxF2iyvgYEC2+1WBAff XHnw==
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
I want to have completion for a command that looks like "command [optional]
required" (i.e. possible completions are either "command required" or
"command optional required").
My understanding is that "_arguments '::message:(optional)'
':message:(required)'" should achieve this effect.
However when I'm trying to use it on zsh 5.6.2, in addition to the expected
commandlines, it also allows to complete "command required required" where
the required argument is repeated twice (but not more). Is this a bug or am
I missing something? Is there another way to get what I want?
Messages sorted by:
Reverse Date,
Date,
Thread,
Author