Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 1 Jun 2002 18:31:47 +0300
From:      Alexey Zelkin <phantom@ark.cris.net>
To:        "Bruce A. Mah" <bmah@FreeBSD.org>
Cc:        doc@FreeBSD.org, nik@FreeBSD.org
Subject:   Re: cvs commit: src/release/doc/en_US.ISO8859-1/relnotes/common new.sgml
Message-ID:  <20020601183147.C55534@ark.cris.net>
In-Reply-To: <200205311443.g4VEhUPi002113@intruder.bmah.org>; from bmah@FreeBSD.org on Fri, May 31, 2002 at 07:43:30AM -0700
References:  <200205302048.g4UKmDh27423@freefall.freebsd.org> <20020531121313.A20879@ark.cris.net> <200205311443.g4VEhUPi002113@intruder.bmah.org>

next in thread | previous in thread | raw e-mail | index | archive | help
[Redirected to -doc]

hi,

On Fri, May 31, 2002 at 07:43:30AM -0700, Bruce A. Mah wrote:

> > What's the problem with referencing -STABLE's man pages instead ? IIRC
> > there're was discussion on the -doc according to modification stylesheet
> > to support references other than -CURRENT.
> 
> The release notes for -CURRENT reference the manpages for -CURRENT on
> the Web site.  The release notes for 4-STABLE reference the manpages for
> 4-STABLE on the Web site.  Exactly as it should be.
Maybe we need to think about it :-)

> (It used to be that all versions of the release notes referenced the
> manpages for the most recent release.  Clearly that doesn't work.)
Currently no, but who can stop you from modifying existing DSL to make
it reality ?

> If you're saying we should refer to 4-STABLE's manpages for those cases
> in -CURRENT where there *is* no manpage, that isn't really going to work
> too well.  As it stands right now, we lack the capability to specify
> which version of a manpage should be used on a case-by-case basis.  

Using attached patches it could become reality.

Actually I am not a docbook guru, but small portion of wish and few hours
spent to review existing stylessheets ... So, using attached patches we can
add exact  release reference to generated  man.cgi url. Updated
&man.*; entity should look like

<!ENTITY man.strings.1 "<longciterefentry/<refentrytitle/strings/<manvolnum/1/<version/4.5-stable//">

We just could ask Wolfram (who manages man.cgi) to change 4.?-stable to
4-stable in man.cgi script and replace all <citerefentry>'es of manpages
removed from -CURRENT with <longciterefentry> (I mean man-refs.ent file)

Thoughts ?

Index: freebsd.dsl
===================================================================
RCS file: /home/cvs/freebsd/doc/share/sgml/freebsd.dsl,v
retrieving revision 1.64
diff -u -r1.64 freebsd.dsl
--- freebsd.dsl	27 Feb 2002 04:56:44 -0000	1.64
+++ freebsd.dsl	1 Jun 2002 15:28:35 -0000
@@ -120,9 +120,11 @@
           ;; /REFENTRY
           #f)
 
-        ; Empty function to quiet warnings
+        ; Empty functions to quiet warnings
         (define ($create-refentry-xref-link$ refentrytitle manvolnum)
           (literal ""))
+        (define ($create-long-refentry-xref-link$ refentrytitle manvolnum manversion)
+          (literal ""))
 
         (element citerefentry
           (let* ((refentrytitle (select-elements (children (current-node))
@@ -132,6 +134,28 @@
 		 (href          ($create-refentry-xref-link$
                                                  (data refentrytitle)
                                                  (data manvolnum))))
+            (if %refentry-xref-link%
+              (create-link (list (list "HREF" href))
+                (if %refentry-xref-italic%
+                  ($italic-seq$)
+                  ($charseq$)))
+              (if %refentry-xref-italic%
+                ($italic-seq$)
+                ($charseq$)))))
+
+	(element manversion (empty-sosofo))
+
+        (element longciterefentry
+          (let* ((refentrytitle (select-elements (children (current-node))
+                                                 (normalize "refentrytitle")))
+		 (manvolnum     (select-elements (children (current-node))
+						 (normalize "manvolnum")))
+		 (manversion    (select-elements (children (current-node))
+						 (normalize "manversion")))
+		 (href          ($create-long-refentry-xref-link$
+                                                 (data refentrytitle)
+                                                 (data manvolnum)
+                                                 (data manversion))))
             (if %refentry-xref-link%
               (create-link (list (list "HREF" href))
                 (if %refentry-xref-italic%
Index: freebsd41.dtd
===================================================================
RCS file: /home/cvs/freebsd/doc/share/sgml/freebsd41.dtd,v
retrieving revision 1.4
diff -u -r1.4 freebsd41.dtd
--- freebsd41.dtd	27 Feb 2002 04:56:44 -0000	1.4
+++ freebsd41.dtd	1 Jun 2002 14:53:27 -0000
@@ -29,6 +29,7 @@
 <!ENTITY % local.tech.char.class "|HostID|Username|Groupname|Devicename|MakeTarget|MakeVar">
 
 <!ENTITY % local.cptr.char.mix "|CO">
+<!ENTITY % local.gen.char.class "|LongCiteRefEntry">
 
 <!-- OS Version attributes ...............................................
 
@@ -123,6 +124,19 @@
 
      In addition, allow our custom addition, <makevar> -->
 <!ELEMENT Filename - - (%smallcptr.char.mix;|Envar|MakeVar)+>
+
+<!-- Extend <citerefentry> to allow to reference manpage of exact release -->
+<!-- <!ELEMENT ManVersion - - ((%word.char.mix;)+)> -->
+<!ELEMENT ManVersion - - (#PCDATA)>
+<!ATTLIST ManVersion
+                %common.attrib;
+>
+
+<!ELEMENT LongCiteRefEntry - - (RefEntryTitle, ManVolNum?, ManVersion)>
+<!ATTLIST LongCiteRefEntry
+                %common.attrib;
+>
 
 <!-- ...................................................................... -->
 <!-- General entities for reuse ........................................... -->

Index: freebsd.dsl
===================================================================
RCS file: /home/cvs/freebsd/doc/en_US.ISO8859-1/share/sgml/freebsd.dsl,v
retrieving revision 1.14
diff -u -r1.14 freebsd.dsl
--- freebsd.dsl	2 Sep 2001 02:37:50 -0000	1.14
+++ freebsd.dsl	1 Jun 2002 14:29:51 -0000
@@ -56,6 +56,14 @@
         (define ($create-refentry-xref-link$ refentrytitle manvolnum)
 	  (string-append "http://www.FreeBSD.org/cgi/man.cgi?query="
 			 refentrytitle "&" "sektion=" manvolnum))
+
+        <!-- Specify how to generate the man page link HREF with FreeBSD
+             release reference -->
+        (define ($create-long-refentry-xref-link$ refentrytitle manvolnum manversion)
+	  (string-append "http://www.FreeBSD.org/cgi/man.cgi?query="
+			 refentrytitle "&" "sektion=" manvolnum "&"
+			 "manpath=" manversion))
+
       ]]>
 
       <!-- More aesthetically pleasing chapter headers for print output --> 

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-doc" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020601183147.C55534>