zsh-users
 help / color / mirror / code / Atom feed
* Compctl completion tweaking
@ 1998-06-23 14:57 Johan Sundström
  1998-06-23 19:38 ` Bart Schaefer
  0 siblings, 1 reply; 2+ messages in thread
From: Johan Sundström @ 1998-06-23 14:57 UTC (permalink / raw)
  To: zsh mailinglist

I've been trying for some time to limit completion behaviour for some
commands in an intelligent manner. What I am trying to do is mask out
files not matching a given pattern, keeping directories intact, or,
better still, matching files according to some pattern and directories
according to some other pattern. Shouldn't that be possible using
something like -g '(*.rpm(.))|(*(-/))'? I tried for a while with some
print -m magic, but didn't quite manage to get it to work.

(Sure, -g '*.rmp(.)' + -g '*(-/)' does a fair job, but I find it
irritating that I cant tab my way down into a subdirectory of a
directory containing *.rpm files this way.)

Secondly, is there any way I can influence the sorting compctl does? I'd
be very happy if some commands' completion list would be sorted
files-first, others' directories-first, and yet others mixed-alpha-sort
(the only method I am aware of being possible). I thought this behaviour
could be mimiced crudely using -K functions, but it seems the function's
output is being sorted. It sure took me a while realizing that... :\

/Johan Sundström


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

end of thread, other threads:[~1998-06-23 20:21 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-06-23 14:57 Compctl completion tweaking Johan Sundström
1998-06-23 19:38 ` Bart Schaefer

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).