zsh-users
 help / color / mirror / code / Atom feed
From: Francis GALIEGUE <fg@mandrakesoft.com>
To: zsh-users@sunsite.auc.dk
Subject: zsh and RPM: a case of study (for me)
Date: Wed, 29 Sep 1999 19:27:17 +0000	[thread overview]
Message-ID: <37F26815.B5B90B8@mandrakesoft.com> (raw)

Hi,

I'm a new subscriber to this list. I've used zsh for only 4 days now,
but to my opinion it plain rocks. It already saves me a lot of time, no
doubt on this, and I've even hacked a bit the base distribution that
comes with it so that it can handle lftp (a change in a #compdef, no big
deal) and .tar.bz2 archives cleanly.

But all the rest is obscure to me.

I've d/led the postscript of the manual and printed out, guess what,
chapters 20, 21 and 23. But I haven't got what I want. Like all manuals,
unfortunately, it's exhaustive but doesn't give enough examples :(

What are really completion widgets? Even after rereading the
aforementioned chapters 3, 4 times I still couldn't figure it out. When
are they called, what do they do, etc, and more importantly, HOW TO
CREATE ONE!

Just for example, lets say I have a:

compctl -X bar -k "(a b)" foo

how can I do so that it's actually a completion widget which returns the
"(a b)" stuff? Or am I missing the point completely?

Another probably dumb example: I'm used to the bash key sequences
(C-x|Esc)(!|@|~|/|$), how can I reproduce them in a simple manner?

And for the hardest part now: a set of functions|widgets|whatever for
rpm...

I make RPMs quite often indeed, and I'd like:

rpm -b<whatever> [ --target=whatever ] <TAB>

to complete on *.spec files,

rpm -q<whatever but p or f> --<TAB> <TAB>

to complete on long options (--queryformat for example) then installed
rpms,

<the above but with -qp>

to complete on *.(src|any_architecture).rpm,

rpm -qf <TAB>

to complete on files, etc.etc. and this is only one major mode of RPM.
The others are certainly easier (also consider the different completions
possible on a --queryformat - ugh)

The problem is that I can generate each of these arrays individually (a
mano for the options), but not tie them together so that it completes
correctly in each of these cases... And I fear that the compctl function
may not be enough for this :(

Oh, also, there seems to be a bug with ZLS_COLORS: empty lines are
stuffed with some random colors and it doesn't like custom foreground
colors for files in the dircolors mechanism...

I don't want this message to look like a rant, it's not - I really love
this shell, but I wish there were a good, explanative, to-the-point
programming guide too...

Regards,
--
fg

# rm *;o
o: command not found


             reply	other threads:[~1999-09-30  2:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-09-29 19:27 Francis GALIEGUE [this message]
1999-09-29 19:53 ` Chmouel Boudjnah
1999-09-29 20:11   ` Adam Spiers
1999-09-30 10:03   ` Francis GALIEGUE
1999-09-29 20:10 ` Adam Spiers
1999-09-30  9:05   ` various completion queries Peter Stephenson
1999-09-30 12:19   ` zsh and RPM: a case of study (for me) Francis GALIEGUE
1999-09-30 16:40     ` Chmouel Boudjnah
1999-09-30 19:10     ` Adam Spiers
1999-10-11 12:14 Sven Wischnowsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=37F26815.B5B90B8@mandrakesoft.com \
    --to=fg@mandrakesoft.com \
    --cc=zsh-users@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).