Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
completion with descriptions
- X-seq: zsh-users 10094
- From: Andy Spiegl <zsh.Andy@xxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: completion with descriptions
- Date: Mon, 27 Mar 2006 15:27:50 +0200
- Kinfo: virscan ok
- Kinfo: !spam auth
- Kreccount: 1
- Mail-followup-to: zsh-users@xxxxxxxxxx
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
How can I provide a description for every offered completion
like e.g. "kill" does it nicely?
# kill t<TAB>
process ID
28745 ? 00:02:11 tudu
28760 ? 00:00:00 tail
28879 pts/7 00:02:08 topcpu
28881 pts/8 00:00:08 tmp-cron-script
In my completion function I tried like this:
':cmds: compadd ${${(f)"$(gigaset --commands)"}%%[[:space:]]##--*}' \
but it only gives me this:
# condor:~>gigaset d<TAB>
del demux details dir divx divxfast dump
although "gigaset --commands" outputs:
...
dir -- Liste der Aufnahmen
dump -- Details anzeigen
details -- (s. dump)
divx -- Aufnahme ins DivX-Format konvertieren
divxfast -- Aufnahme (schneller) ins DivX-Format konvertieren
demux -- Aufnahme mit projectX demultiplexen
del -- (s. rm)
...
For the last hours I read the manual and examples (like _pids) but
eventually got lost before finding the solution :-(
Thanks,
Andy.
--
Finagle's First Law:
If an experiment works, something has gone wrong.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author