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

Autocomplet with compdef _precommand



Hello,

I use zsh (5.0.7) with the autocd option. I create a function start() that
will run another command :

function start (){
    "$@" &> /dev/null &
}

And I add this line to have autocomplet :

compdef _precommand start

But when I run, for example "start ssh example.com" zsh want replace "ssh"
by ".ssh/" (if I am in $HOME). I think that is because autocd change the
behaviour of _precommand.

How can I use a autocomplet like p_precommand but without the autocd
behavur ?

Thanks for your help!


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