Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: default tag-order (was Re: zsh 4.2.1-test-A)
- X-seq: zsh-workers 20243
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Zsh <zsh-workers@xxxxxxxxxx>
- Subject: Re: default tag-order (was Re: zsh 4.2.1-test-A)
- Date: Sun, 8 Aug 2004 09:46:22 -0700 (PDT)
- In-reply-to: <Pine.LNX.4.61.0408080837190.16667@xxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <200408061350.i76DovBi028948@xxxxxxxxxxxxxx> <20040806180339.GA31854@xxxxxxxxxxx> <10094.1091886003@xxxxxxxxxxxxxxxxxxxxx> <20040808044557.GA8117@xxxxxxxxxxx> <16609.1091976020@xxxxxxxxxxxxxxxxxxxxx> <Pine.LNX.4.61.0408080837190.16667@xxxxxxxxxxxxxxxxxx>
- Reply-to: zsh-workers@xxxxxxxxxx
On Sun, 8 Aug 2004, Bart Schaefer wrote:
> On Sun, 8 Aug 2004, Oliver Kiddle wrote:
>
> > The problem is with the default tag-order defined in _tags. The relevant
> > bit of code is as follows:
> > zstyle -a ":completion:${curcontext}:" tag-order order ||
> > order=('(|*-)argument-* (|*-)option[-+]* values' options)
> >
> > One safe option is to insert `(( ! ${@[(I)options]} )) ||'.
> > That checks if there is an options tag before applying the tag-order.
>
> I'm confused by this suggestion. If there's no options tag, the tag-order
> doesn't make any difference, because it's in the second group of tags.
> And in the case of cdrecord, there _is_ an options tag.
OK, I worked this out now. The problem is that there's no options tag *in
the argument-rest subcontext* but there are both values and files tags, so
the presence of values in this tag hides the files. Sorry to be dense.
The canonical examples of _values are _dd and _chmod, neither of which
allows ambiguity in whether an argument is a value or a filename (dd takes
only values, and chmod requires exactly one value before any filename).
So I suspect this simply never came up before.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author