Zsh Mailing List Archive
Messages sorted by:
Re: Completion function for bitkeeper?
- X-seq: zsh-users 6755
- From: Danek Duvall <duvall@xxxxxxxxxxx>
- To: Oliver Kiddle <okiddle@xxxxxxxxxxx>
- Subject: Re: Completion function for bitkeeper?
- Date: Mon, 10 Nov 2003 10:20:13 -0800
- Cc: Jonas Juselius <jonas@xxxxxx>, zsh-users@xxxxxxxxxx
- In-reply-to: <1281.1068232665@athlon>
- Mail-followup-to: Danek Duvall <duvall@xxxxxxxxxxx>, Oliver Kiddle <okiddle@xxxxxxxxxxx>, Jonas Juselius <jonas@xxxxxx>, zsh-users@xxxxxxxxxx
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20030523160020.GA9026@xxxxxxxxx> <20030523160155.GA14388@xxxxxxxxxxxxxxxxxx> <20031106153225.GA491@xxxxxxxxxxxxxxxxxx> <1281.1068232665@athlon>
On Fri, Nov 07, 2003 at 08:17:45PM +0100, Oliver Kiddle wrote:
> Looking inside expl is not a good idea as the array name expl is
> purely a convention.
I agree that if it's merely a convention that I shouldn't use it.
However, the zshcompsys man page explicitly documents it, suggesting
that it's safe to use. If it's not, perhaps removing it from the
documentation is the right thing to do.
> Try using zparseopts to find and remove that -e option instead:
> zparseopts -D -E e=eopt
> [[ -n $eopt ]] && sfile="SCCS/p."
That works, thanks.
Still, this whole thing feels like a fragile interface. Two entirely
different sets of information are being passed to the function on the
commandline, which at the very least means that there's a potential for
flag collision (what happens if _arguments decides to pass in -e for
compadd purposes?), never mind the parsing difficulties.
It seems that using some other method for passing in compadd arguments
would be better ... such as using a well-known parameter name. :)
I still maintain that passing in the compadd arguments both on the
commandline and in $expl is a bug, as it's duplicative, redundant,
repetitive, and redundant.
Messages sorted by: