Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: [Q] user-defined completion



Didier Verna wrote:

> 
> Sven Guckes <guckes@xxxxxxxxxxxxxxxxx> writes:
> 
> > Quoting Didier Verna (verna@xxxxxxxxxxx): > I'd like to write a function for
> > special command line completion, but that is > aware of the program whose
> > command line we're completing. After reading the > doc, I see that
> > user-defined functions get 2 arguments: pre and postfix. Is there a way to
> > make such functions aware of the program name ? Any ideas ?
> 
> > Are talking about "completion control" with "compctl"?  
> 
> 	Possibly, yes.
> 
> 
> > "man zshcompctl"!
> 
> 	That's what I meant by saying "after reading the doc". But it seems
> that the answer is no. So, in case I'm missing something, or I'm just blind,
> I would have liked to know if somebody knows a way to achieve this.
> 

Hm, I already answered this: look at the `read'-builtin (options `-c', 
`-l' and so on).

A quick look at the manual reveals that this is really hidden a bit
too deeply: it is mentioned at the `-U'-option, not at `-K'.

Bye
 Sven


--
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



Messages sorted by: Reverse Date, Date, Thread, Author