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

Re: Completion: How to emulate what this zstyle does natuarlly in a completion function?



On Sat, May 26, 2018 at 12:05 AM, Doron Behar <doron.behar@xxxxxxxxx> wrote:
>
> My question is: How do I emulate a completion like that naturally within
> a completion function? I want a certain command's option argument
> completion to suggest all processes the current user just like when I
> try to complete `kill`.

You want to call the _pids helper function from that command's
completion function.  _pids will use the current context to look up
the command to use to generate the list of possible process IDs.



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