/[gentoo]/xml/htdocs/doc/en/xml-guide.xml
Gentoo

Diff of /xml/htdocs/doc/en/xml-guide.xml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.68 Revision 1.72
1<?xml version="1.0" encoding="UTF-8"?> 1<?xml version="1.0" encoding="UTF-8"?>
2<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/xml-guide.xml,v 1.68 2008/03/09 13:13:15 neysx Exp $ -->
3<!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> 2<!DOCTYPE guide SYSTEM "/dtd/guide.dtd">
3<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/xml-guide.xml,v 1.72 2012/10/07 08:19:42 swift Exp $ -->
4 4
5<guide> 5<guide>
6<title>Gentoo GuideXML Guide</title> 6<title>Gentoo GuideXML Guide</title>
7 7
8<author title="Author"> 8<author title="Author">
18 <mail link="peesh@gentoo.org">Jorge Paulo</mail> 18 <mail link="peesh@gentoo.org">Jorge Paulo</mail>
19</author> 19</author>
20<author title="Editor"> 20<author title="Editor">
21 <mail link="swift@gentoo.org">Sven Vermeulen</mail> 21 <mail link="swift@gentoo.org">Sven Vermeulen</mail>
22</author> 22</author>
23<author title="Editor">
24 <mail link="nightmorph"/>
25</author>
23 26
24<abstract> 27<abstract>
25This guide shows you how to compose web documentation using the new lightweight 28This guide shows you how to compose web documentation using the new lightweight
26Gentoo GuideXML syntax. This syntax is the official format for Gentoo 29Gentoo GuideXML syntax. This syntax is the official format for Gentoo
27documentation, and this document itself was created using GuideXML. This guide 30documentation, and this document itself was created using GuideXML. This guide
30 33
31<!-- The content of this document is licensed under the CC-BY-SA license --> 34<!-- The content of this document is licensed under the CC-BY-SA license -->
32<!-- See http://creativecommons.org/licenses/by-sa/2.5 --> 35<!-- See http://creativecommons.org/licenses/by-sa/2.5 -->
33<license/> 36<license/>
34 37
35<version>9</version> 38<version>13</version>
36<date>2008-03-09</date> 39<date>2012-10-07</date>
37 40
38<chapter> 41<chapter>
39<title>GuideXML basics</title> 42<title>GuideXML basics</title>
40<section> 43<section>
41<title>GuideXML design goals</title> 44<title>GuideXML design goals</title>
90<pre caption="The initial part of a guide XML document"> 93<pre caption="The initial part of a guide XML document">
91&lt;?xml version="1.0" encoding="UTF-8"?&gt; 94&lt;?xml version="1.0" encoding="UTF-8"?&gt;
92&lt;!DOCTYPE guide SYSTEM "/dtd/guide.dtd"&gt; 95&lt;!DOCTYPE guide SYSTEM "/dtd/guide.dtd"&gt;
93&lt;!-- &#36;Header&#36; --&gt; 96&lt;!-- &#36;Header&#36; --&gt;
94 97
95&lt;guide link="<i>/doc/en/guide.xml</i>" lang="<i>en</i>"&gt; 98&lt;guide lang="<i>en</i>"&gt;
96&lt;title&gt;<i>Gentoo Documentation Guide</i>&lt;/title&gt; 99&lt;title&gt;<i>Gentoo Documentation Guide</i>&lt;/title&gt;
97 100
98&lt;author title="<i>Author</i>"&gt; 101&lt;author title="<i>Author</i>"&gt;
99 &lt;mail link="<i>yourname@gentoo.org</i>"&gt;<i>Your Name</i>&lt;/mail&gt; 102 &lt;mail link="<i>yourname@gentoo.org</i>"&gt;<i>Your Name</i>&lt;/mail&gt;
100&lt;/author&gt; 103&lt;/author&gt;
105format for Gentoo web documentation, and this document itself was created 108format for Gentoo web documentation, and this document itself was created
106using GuideXML.</i> 109using GuideXML.</i>
107&lt;/abstract&gt; 110&lt;/abstract&gt;
108 111
109&lt;!-- The content of this document is licensed under the CC-BY-SA license --&gt; 112&lt;!-- The content of this document is licensed under the CC-BY-SA license --&gt;
110&lt;!-- See http://creativecommons.org/licenses/by-sa/2.5 --&gt; 113&lt;!-- See http://creativecommons.org/licenses/by-sa/3.0 --&gt;
111&lt;license/&gt; 114&lt;license version="3.0"/&gt;
112 115
113&lt;version&gt;<i>1.0</i>&lt;/version&gt; 116&lt;version&gt;<i>1</i>&lt;/version&gt;
114&lt;date&gt;<i>2004-12-25</i>&lt;/date&gt; 117&lt;date&gt;<i>2011-11-29</i>&lt;/date&gt;
115</pre> 118</pre>
116 119
117<p> 120<p>
118On the first lines, we see the requisite tag that identifies this as an XML 121On the first lines, we see the requisite tag that identifies this as an XML
119document and specifies its DTD. The <c>&lt;!-- &#36;Header&#36; --&gt;</c> line 122document and specifies its DTD. The <c>&lt;!-- &#36;Header&#36; --&gt;</c> line
120will be automatically modified by the CVS server and helps to track revisions. 123will be automatically modified by the CVS server and helps to track revisions.
121Next, there's a <c>&lt;guide&gt;</c> tag -- the entire guide document is 124Next, there's a <c>&lt;guide&gt;</c> tag -- the entire guide document is
122enclosed within a <c>&lt;guide&gt; &lt;/guide&gt;</c> pair. 125enclosed within a <c>&lt;guide&gt; &lt;/guide&gt;</c> pair.
123<br/>
124The <c>link</c> attribute is optional and should preferably contain the
125absolute path to the document relatively to the document root even though the
126file name alone will work. It is only used to generate a link to a
127printer-friendly version of your document and check whether a translation is
128up-to-date. Our XSL back-engine passes the actual path to our XSL stylesheet.
129The link attribute is only used as a fall-back value in case the XML is
130processed by other means.
131<br/> 126<br/>
132The <c>lang</c> attribute should be used to specify the language code of your 127The <c>lang</c> attribute should be used to specify the language code of your
133document. It is used to format the date and insert strings like "<e>Note</e>", 128document. It is used to format the date and insert strings like "<e>Note</e>",
134"<e>Content</e>", etc. in the specified language. The default is English. 129"<e>Content</e>", etc. in the specified language. The default is English.
135</p> 130</p>
165<c>&lt;guide&gt;</c> tag, and for consistency it's recommended (but not 160<c>&lt;guide&gt;</c> tag, and for consistency it's recommended (but not
166required) that these tags appear before the content of the document. 161required) that these tags appear before the content of the document.
167</p> 162</p>
168 163
169<p> 164<p>
170Finally we have the <c>&lt;license/&gt;</c> tag, used to publish the document 165Finally we have the <c>&lt;license version="3.0"/&gt;</c> tag, used to publish
171under the <uri link="http://creativecommons.org/licenses/by-sa/2.5/">Creative 166the document under the <uri link="http://creativecommons.org/licenses/by-sa/3.0/">Creative
172Commons - Attribution / Share Alike</uri> license as required by the <uri 167Commons - Attribution / Share Alike</uri> license as required by the <uri
173link="/proj/en/gdp/doc/doc-policy.xml">Documentation Policy</uri>. 168link="/proj/en/gdp/doc/doc-policy.xml">Documentation Policy</uri>. Historically,
169the tag <c>&lt;license /&gt;</c> was used, which denoted the 2.5 version of the
170license. This is still accepted/allowed.
174</p> 171</p>
175 172
176</body> 173</body>
177</section> 174</section>
178<section> 175<section>
445<p> 442<p>
446Sample colour-coded <c>&lt;pre&gt;</c> block: 443Sample colour-coded <c>&lt;pre&gt;</c> block:
447</p> 444</p>
448 445
449<pre caption="My first ebuild"> 446<pre caption="My first ebuild">
450<comment># Copyright 1999-2006 <b>Gentoo Foundation</b> 447<comment># Copyright 1999-2009 <b>Gentoo Foundation</b>
451# Distributed under the terms of the GNU General Public License v2 448# Distributed under the terms of the GNU General Public License v2
452# &#36;Header: $</comment> 449# &#36;Header: $</comment>
453 450
454<ident>DESCRIPTION</ident>=<const>"Exuberant ctags generates tags files for quick source navigation"</const> 451<ident>DESCRIPTION</ident>=<const>"Exuberant ctags generates tags files for quick source navigation"</const>
455<ident>HOMEPAGE</ident>=<const>"http://ctags.sourceforge.net"</const> 452<ident>HOMEPAGE</ident>=<const>"http://ctags.sourceforge.net"</const>
459<ident>SLOT</ident>=<const>"0"</const> 456<ident>SLOT</ident>=<const>"0"</const>
460<ident>KEYWORDS</ident>=<const>"~mips ~sparc ~x86"</const> 457<ident>KEYWORDS</ident>=<const>"~mips ~sparc ~x86"</const>
461<ident>IUSE</ident>=<const>""</const> 458<ident>IUSE</ident>=<const>""</const>
462 459
463<stmt>src_compile()</stmt> { 460<stmt>src_compile()</stmt> {
464 <keyword>econf</keyword> --with-posix-regex || <keyword>die</keyword> <const>"econf failed"</const> 461 <keyword>econf</keyword> --with-posix-regex
465 <keyword>emake</keyword> || <keyword>die</keyword> <const>"emake failed"</const> 462 <keyword>emake</keyword> || <keyword>die</keyword> <const>"emake failed"</const>
466} 463}
467 464
468<stmt>src_install()</stmt> { 465<stmt>src_install()</stmt> {
469 <keyword>make</keyword> <ident>DESTDIR</ident>="<var>${D}</var>" install || <keyword>die</keyword> <const>"install failed"</const> 466 <keyword>make</keyword> <ident>DESTDIR</ident>="<var>${D}</var>" install || <keyword>die</keyword> <const>"install failed"</const>
812&lt;abstract&gt; 809&lt;abstract&gt;
813 ... 810 ...
814&lt;/abstract&gt; 811&lt;/abstract&gt;
815 812
816&lt;!-- The content of this document is licensed under the CC-BY-SA license --&gt; 813&lt;!-- The content of this document is licensed under the CC-BY-SA license --&gt;
817&lt;!-- See http://creativecommons.org/licenses/by-sa/2.5 --&gt; 814&lt;!-- See http://creativecommons.org/licenses/by-sa/3.0 --&gt;
818&lt;license/&gt; 815&lt;license version="3.0"/&gt;
819 816
820&lt;version&gt;...&lt;/version&gt; 817&lt;version&gt;...&lt;/version&gt;
821&lt;date&gt;...&lt;/date&gt; 818&lt;date&gt;...&lt;/date&gt;
822</pre> 819</pre>
823 820
874&lt;?xml version='1.0' encoding='UTF-8'?&gt; 871&lt;?xml version='1.0' encoding='UTF-8'?&gt;
875&lt;!DOCTYPE sections SYSTEM "/dtd/book.dtd"&gt; 872&lt;!DOCTYPE sections SYSTEM "/dtd/book.dtd"&gt;
876&lt;!-- &#36;Header&#36; --&gt; 873&lt;!-- &#36;Header&#36; --&gt;
877 874
878&lt;!-- The content of this document is licensed under the CC-BY-SA license --&gt; 875&lt;!-- The content of this document is licensed under the CC-BY-SA license --&gt;
879&lt;!-- See http://creativecommons.org/licenses/by-sa/2.5 --&gt; 876&lt;!-- See http://creativecommons.org/licenses/by-sa/3.0 --&gt;
880 877
881&lt;sections&gt; 878&lt;sections&gt;
882 879
883&lt;abstract&gt; 880&lt;abstract&gt;
884 This is a small explanation on chapter one. 881 This is a small explanation on chapter one.

Legend:
Removed from v.1.68  
changed lines
  Added in v.1.72

  ViewVC Help
Powered by ViewVC 1.1.20