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

Re: MH completion



Peter Stephenson wrote:

> I was trying to rewrite MH completion to use _arguments; you can run
> `command -help' and make the argument list up from the output as you
> go along.  But it looks like _arguments can't deal with the +folder
> syntax, i.e. that anything beginning with a + needs to be completed
> specially by a separate function/state.  Ideas?

It seems like I have the manuals for `mh' here, but not the binaries,
so I can't help much, I fear.

And I can only think of 1) first testing for `[[ $PREFIX = +* ]]' and
calling `_arguments' in the else branch or 2) let `_arguments' set a
certain state for those places where +folder is valid and handle that
after return from `_arguments', testing if the word starts with a `+', 
complete folders then and otherwise complete the things that are
allowed there, too (if any).

(I don't know `mh', so I can't say if one of these is possible/correct.)

Bye
 Sven


--
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



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