From: "Thomas Köhler" <jean-luc@picard.franken.de>
To: zsh-users@math.gatech.edu
Subject: man compctl
Date: Fri, 23 Jan 1998 22:22:36 +0100 [thread overview]
Message-ID: <19980123222236.60814@picard.franken.de> (raw)
In-Reply-To: <82hg6zowz8.fsf@y.idonex.se>
Hello all,
here's my completion for manpages.
# completion for manpages
####
# if ~/tmp/_man_ is too old then remove it and create a new one later
find ~/tmp -mtime 14 -name "_man_" -exec rm -f {} \;
createman () {
echo "creating ~/tmp/_man_"
find /usr/man -type f > ~/tmp/_man_
find /usr/local/man -type f >> ~/tmp/_man_
find /usr/X11R6/man -type f >> ~/tmp/_man_
sed -e "s/.*\///" -e "s/\.gz//" -e "s/\.[^.]*$//" ~/tmp/_man_ | sort | uniq > ~/tmp/_man2_
rm -f ~/tmp/_man_
(for i in `cat ~/tmp/_man2_` ; do echo -n "$i " ; done) > ~/tmp/_man_
rm -f ~/tmp/_man2_
}
if [ ! -f ~/tmp/_man_ ] ; then createman ; fi
####
man_pages=(`cat ~/tmp/_man_`)
compctl -f -k man_pages man
Remarks:
the first part (#### - ####) should better be put in a cron job or in
your .zlogout (if you don't have access to crontab) - it may take some
time to process those finds :-)
CU,
Thomas
--
-- Thomas Köhler Email: jean-luc@picard.franken.de
<>< jean-luc@mayn.de
IRC: jeanluc Channels: #star_trek #linuxger #ixthys #knf
WWW: http://home.pages.de/~jeanluc/
next prev parent reply other threads:[~1998-01-24 9:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
1998-01-20 12:00 tar compctl Niall Smart
1998-01-20 17:51 ` CVS compctl Mirar
1998-01-23 21:22 ` Thomas Köhler [this message]
1998-01-24 11:37 ` man compctl Mirar
1998-01-24 11:57 ` misc compctl Mirar
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=19980123222236.60814@picard.franken.de \
--to=jean-luc@picard.franken.de \
--cc=zsh-users@math.gatech.edu \
/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).