Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: matching control for completion (with PATCH)
- X-seq: zsh-workers 4364
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxxx
- Subject: Re: matching control for completion (with PATCH)
- Date: Thu, 27 Aug 1998 08:49:38 +0200 (MET DST)
- In-reply-to: "Bart Schaefer"'s message of Wed, 26 Aug 1998 09:57:00 -0700
Bart Schaefer wrote:
>
> On Aug 26, 3:59pm, Sven Wischnowsky wrote:
> } Subject: matching control for completion (with PATCH)
> }
> } E.g. if one wants to say
> } that a lowercase letter on the command line matches an upeprcase
> } letter in the words, one can say: `m:{a-z}={A-Z}'.
>
> What happens if there aren't the same number of characters in each class?
>
If one class has n characters and the other has m , with n < m, only
the first n characters in both classes match (since the others have no
corresponding character).
> } compctl -M 'r:|[-.,_/]=* r:|=* m:{a-z}={A-Z}' 'l:|=* r:|=*'
>
> I dunno, Sven; I think if you'd tried you could have made that a little
> more cryptic.
>
Damn, I should have used my first implementation (the would have been
`"<[-.,_/]=* <=* {a-z}={A-z}" ">=* <=*"' for the above).
But for me the internals of the code was simply more interesting than
spending even more time in finding a nice syntax (whic really isn't
that easy), especially since we seem to seriously think about a new
way to define completions.
Bye
Sven
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author