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

Re: Completion on simple commande



Michel wrote:
> I use an zsh function to launch the graphical application. But I don't
> know how have the completion on my function.
>
> My function is :
> function start (){
>     $@ > /dev/null 2> /dev/null &
> }

You probably want to use "$@" (double-quoted) here.

> And I want can type :
> start fire<tab>
>
> To launch firefox. In bash I know the "complete" commande but I don't
> know the zsh metode.

compdef _precommand start

That will make the command-specific version work, too.

Regards, Frank

-- 
In protocol design, perfection has been reached not when there is
nothing left to add, but when there is nothing left to take away.
                                                  -- RFC 1925



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