Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Completion on simple commande
- X-seq: zsh-users 15266
- From: Frank Terbeck <ft@xxxxxxxxxxxxxxxxxxx>
- To: Michel <michel.barret@xxxxxxxxx>
- Subject: Re: Completion on simple commande
- Date: Thu, 12 Aug 2010 11:56:31 +0200
- Cc: zsh-users@xxxxxxx
- In-reply-to: <AANLkTinxZLq8ao5zGcKA_L2ASRzgNEGNjKo3rW0VC3Cn@xxxxxxxxxxxxxx> (Michel's message of "Thu, 12 Aug 2010 11:11:11 +0200")
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
- References: <AANLkTinxZLq8ao5zGcKA_L2ASRzgNEGNjKo3rW0VC3Cn@xxxxxxxxxxxxxx>
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