From: Tanaka Akira <akr@jaist.ac.jp>
To: zsh-workers@sunsite.auc.dk (Zsh hackers list)
Subject: Re: PATCH: 3.1.6-pws-3: _man
Date: 09 Sep 1999 20:21:21 +0900 [thread overview]
Message-ID: <rsqemg8mitq.fsf@crane.jaist.ac.jp> (raw)
In-Reply-To: Peter Stephenson's message of "Thu, 09 Sep 1999 11:44:30 +0200"
This is another patch for _man to handle gzipped and/or SGML manual.
Index: Completion/User/_man
===================================================================
RCS file: /projects/zsh/zsh/Completion/User/_man,v
retrieving revision 1.1.1.6
diff -u -F^( -r1.1.1.6 _man
--- _man 1999/09/09 09:47:08 1.1.1.6
+++ _man 1999/09/09 11:19:28
@@ -1,6 +1,6 @@
#compdef man
-setopt localoptions rcexpandparam
+setopt localoptions rcexpandparam extendedglob
local rep expl star approx
@@ -14,12 +14,14 @@
approx="(#a${_comp_correct})"
fi
+# `sman' is the SGML manual directory for Solaris 7.
+
if [[ $words[2] = (<->*|ln) ]]; then
rep=(
- $manpath/(man|cat)${words[2]}/${~approx}$PREFIX${~star}$SUFFIX.<->*(N:t:r) )
+ $manpath/(sman|man|cat)${words[2]}/${~approx}$PREFIX${~star}$SUFFIX.<->*(N:t) )
else
- rep=( $manpath/(man|cat)*/${~approx}$PREFIX${~star}$SUFFIX.<->*(N:t:r) )
+ rep=( $manpath/(sman|man|cat)*/${~approx}$PREFIX${~star}$SUFFIX.<->*(N:t) )
fi
_description expl 'manual page'
-(( $#rep )) && compadd "$expl[@]" - $rep
+(( $#rep )) && compadd "$expl[@]" - ${rep%%.[^.]##(.gz|)}
--
Tanaka Akira
prev parent reply other threads:[~1999-09-09 11:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
1999-09-09 9:44 Peter Stephenson
1999-09-09 11:21 ` Tanaka Akira [this message]
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=rsqemg8mitq.fsf@crane.jaist.ac.jp \
--to=akr@jaist.ac.jp \
--cc=zsh-workers@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).