From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9853 invoked from network); 9 Sep 1999 11:21:50 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 9 Sep 1999 11:21:50 -0000 Received: (qmail 26238 invoked by alias); 9 Sep 1999 11:21:29 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7740 Received: (qmail 26231 invoked from network); 9 Sep 1999 11:21:27 -0000 To: zsh-workers@sunsite.auc.dk (Zsh hackers list) Subject: Re: PATCH: 3.1.6-pws-3: _man References: <199909090944.LAA10206@paris.ifh.de> MIME-Version: 1.0 (generated by AKEMI 1.13.2 - =?ISO-2022-JP?B?Ig==?= =?ISO-2022-JP?B?GyRCQTA0Y0s8GyhCIg==?=) Content-Type: text/plain; charset=US-ASCII From: Tanaka Akira Date: 09 Sep 1999 20:21:21 +0900 In-Reply-To: Peter Stephenson's message of "Thu, 09 Sep 1999 11:44:30 +0200" Message-ID: User-Agent: Chao-gnus/6.12.5 AKEMI/1.13.2 (=?ISO-2022-JP?B?GyRCQTAbKEI=?= =?ISO-2022-JP?B?GyRCNGNLPBsoQg==?=) FLAM-DOODLE/1.12.6 (=?ISO-2022-JP?B?GyRCM3cbKEI=?= 10R4.0/5.0) Emacs/20.4 (sparc-sun-solaris2.6) MULE/4.0 (HANANOEN) 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