Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 18 Dec 2011 13:36:18 +0300
From:      Sergey Kandaurov <pluknet@gmail.com>
To:        Dmitry Morozovsky <marck@rinet.ru>
Cc:        freebsd-doc@freebsd.org
Subject:   Re: Adding entity to books formatting
Message-ID:  <CAE-mSOKbmVYh1zFen%2BL3dmt%2BPn564Ci83cBHpVz7Cz3L6d8AZw@mail.gmail.com>
In-Reply-To: <alpine.BSF.2.00.1112171718430.58132@woozle.rinet.ru>
References:  <alpine.BSF.2.00.1112151212280.24823@woozle.rinet.ru> <CAE-mSO%2B_K87Js24QQwy_2W7LpNyF3q79M131ZpxhhFAoS8CcQw@mail.gmail.com> <alpine.BSF.2.00.1112171718430.58132@woozle.rinet.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
On 17 December 2011 17:20, Dmitry Morozovsky <marck@rinet.ru> wrote:
> On Sat, 17 Dec 2011, Sergey Kandaurov wrote:
>
>> > I need an advice from dsl-fu-knowledgeable perswon ;)
>> >
>> > Prodded by glebius@, I'm trying to add new entity svnref to generate a=
 link to
>> > svnweb.
>> >
>> > My quick patch stopped with an erro, while generating seems-to-be-corr=
ect
>> > content:
>> >
>> > -- 8< --
>> > marck@woozle:~/FreeBSD/doc/en_US.ISO8859-1/books/porters-handbook> gre=
p -6i
>> > svnref freebsd-versions.html
>> >>Dec 12, 2011</TD
>> >><TD
>> >>10-CURRENT after defining boolean true/false in sys/types.h,
>> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0sizeof(bool) may had change=
d (rev <A
>> > HREF=3D"http://svnweb.freebsd.org/base?view=3Drevision&amp;revision=3D=
228444"
>> >><TT
>> > CLASS=3D"SVNREF"
>> >>228444</TT
>> >></A
>> >>).
>> > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0<TT
>> > CLASS=3D"FILENAME"
>> >>foofile</TT
>>
>> You most probably need to modify share/sgml/freebsd41.dtd as well.
>> Something like these lines:
>>
>> +<!ELEMENT SVNRef - - ((%cptr.char.mix;)+)>
>> +<!ATTLIST SVNRef
>> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0%common.attrib;
>> +>
>> +
>>
>> Hope this helps.
>
> Thanks!
>
> Not exactly ;) -- now it's recognized but specifically disallowed:

Eh, sure. You also need to add it to local.tech.char.class.
Sorry, I forgot to mention this previously. See also how devicename
is implemented. A complete diff below on top of your changes, and
it should work now (it works for me):

doc/share/sgml/freebsd41.dtd or doc/share/sgml/freebsd.dtd ?
What DTD file is actually used is not clear for me. I chose freebsd41.dtd

@@ -26,7 +26,7 @@
 <!-- Entities for element classes and mixtures ...........................=
 -->

 <!-- Character level classes -->
-<!ENTITY % local.tech.char.class
"|HostID|Username|Groupname|Devicename|MakeTarget|MakeVar">
+<!ENTITY % local.tech.char.class
"|HostID|Username|Groupname|Devicename|MakeTarget|MakeVar|SVNRef">

 <!ENTITY % local.cptr.char.mix "|CO">

@@ -116,6 +116,11 @@
                 %common.attrib;
 >

+<!ELEMENT SVNRef - - ((%cptr.char.mix;)+)>
+<!ATTLIST SVNRef
+                %common.attrib;
+>
+
 <!-- The content model for <filename> was changed between DocBook 3.1 and
      4.1.  Specifically, <envar> was disallowed.  There's a suggestion fro=
m
      the DocBook maintainers that this may have been a mistake.  In the

--=20
wbr,
pluknet



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAE-mSOKbmVYh1zFen%2BL3dmt%2BPn564Ci83cBHpVz7Cz3L6d8AZw>