zsh-users
 help / color / mirror / code / Atom feed
* _describe usage
@ 2004-09-08  8:06 Boyd Adamson
  2004-09-08 13:34 ` Oliver Kiddle
  0 siblings, 1 reply; 2+ messages in thread
From: Boyd Adamson @ 2004-09-08  8:06 UTC (permalink / raw)
  To: zsh-users

Hi,

I'm working on my first completion code for a non-trivial command, and I
don't understand what _describe is doing (or how to get it to do what I
want).

What I want is to see something like this in menu selection:
fruit
apple   banana
animal
cat     dog   

I've tried a couple of approaches. My reading of the man page seems to
imply I can do this:

    rts=(apple banana)
    srts=(cat dog)
    _describe "fruit" rts -- "animal" srts

But that gets me this:

jarrah:/# scrgadm -a -j blah -t <tab>
fruit
        apple   banana

and if I menuselect to the blank position under "fruit" I get "cat" on
the commmand line!

I also tried this:

    rts=(apple banana)
    srts=(cat dog)
    _describe "fruit" rts 
    _describe "animal" srts 

But then I see:

jarrah:/# scrgadm -a -j blah -t <tab>
fruit
animal
apple   banana  cat     dog   


What am I doing wrong?


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-09-08 13:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-09-08  8:06 _describe usage Boyd Adamson
2004-09-08 13:34 ` Oliver Kiddle

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).