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

Re: old or new style completion?



On Sun, Sep 30, 2007 at 03:30:48AM +1200, Atom Smasher wrote:
> 1) if the completion widget for rsync farts after the "--" option, that's a 
> problem with the _rsync function.

Yes, _rsync is broken.

> 2) whether i declare "cpv" as an alias or a function, the completion system 
> "interprets it" as the command is rsync, not cpv. if there's no way around 
> that it seems like a problem with the completion system... no?

You are incorrect.  Try
cpv() {
rsync "$@"
}

You will not get rsync completion unless you do a "compdef _rsync cpv".
You could demand cp-like completion instead with "compdef _cp cpv",
though that would not be useful.  If you are witnessing different
results, perhaps you still have your alias set.



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