From 06690997c78d1edecdd5fd53d31d39a6742a928e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=B6kt=C3=BCrk=20Y=C3=BCksek?=
Date: Sat, 29 Oct 2016 20:29:31 -0400
Subject: [PATCH 1/2] devbook.xsl: add support for disabling word-wrapping for
table items
---
devbook.xsl | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/devbook.xsl b/devbook.xsl
index dce6595..b678170 100644
--- a/devbook.xsl
+++ b/devbook.xsl
@@ -104,6 +104,10 @@
+
+
+
+
--
2.7.3
From 5b7cfbad923a67b1b187aec17bcd500cb3c7e430 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=B6kt=C3=BCrk=20Y=C3=BCksek?=
Date: Sat, 29 Oct 2016 20:33:15 -0400
Subject: [PATCH 2/2] eclass-writing: improve the eclass documentation sections
Replace the eclass documentation text blobs from eclass-manpages with
tables. Add a section for eclass function variables.
---
eclass-writing/text.xml | 469 ++++++++++++++++++++++++++++++++++++++++++------
1 file changed, 417 insertions(+), 52 deletions(-)
diff --git a/eclass-writing/text.xml b/eclass-writing/text.xml
index 9329d88..c759849 100644
--- a/eclass-writing/text.xml
+++ b/eclass-writing/text.xml
@@ -125,19 +125,16 @@ adhere to the following process:
-Eclasses are documented as any other bash project is, with code
-comments. We do however have a standard format for eclass, variable,
-and function headers. The app-portage/eclass-manpages package
-processes these headers to create documentation for the eclass. The
-result can be seen in our eclass
-reference, or by installing app-portage/eclass-manpages.
+Eclasses are documented with comment blocks which follow a special
+markup syntax. The comment blocks are separated by empty new lines and
+each block documents an individual entity of an eclass.
-The format for eclass, variable, and function headers are described
-below. Before committing your eclass, please ensure that the
-eclass-to-manpage.sh script (currently in $FILESDIR for
-app-portage/eclass-manpages in the gentoo.git repo) does
-not report any errors or serious warnings for your eclass.
+Documentation tags for various eclass elements are explained in their
+respective sections below. Common to all the tags which accept
+multiline freetext, the @CODE tag should be used when necessary
+to create unformatted code chunks (such as example code) by placing
+the tag at the beginning and the end.
@@ -157,26 +154,135 @@ underscores and dots. Eclasses are not intrinsically versioned.
Eclasses should start with the standard ebuild header, along with
comments explaining the maintainer and purpose of the eclass, and any
-other relevant documentation. The format supported by
-app-portage/eclass-manpages is as follows:
+other relevant documentation. Eclass documentation block should be the
+first documentation block to appear in the eclass. The following table
+summarizes the available documentation tags:
-
-# @ECLASS: foo.eclass
-# @MAINTAINER:
-# <required; list of contacts, one per line>
-# @AUTHOR:
-# <optional; list of authors, one per line>
-# @BUGREPORTS:
-# <optional; description of how to report bugs;
-# default: tell people to use bugs.gentoo.org>
-# @VCSURL: <optional; url to vcs for this eclass; default: https://gitweb.gentoo.org/repo/gentoo.git/log/eclass/@ECLASS@>
-# @BLURB: <required; short description>
-# @DESCRIPTION:
-# <optional; long description>
-# @EXAMPLE:
-# <optional; example usage>
-
+
+
+ tag |
+ optional? |
+ arguments |
+ description |
+
+
+
+ @ECLASS:
+
+
+ NO
+
+
+ Name of the eclass being documented.
+
+
+ Documents various information about the eclass. Must appear as the
+ first tag in the comment block.
+
+
+
+
+ @MAINTAINER:
+
+
+ NO
+
+
+ One or more name and email pairs.
+
+
+ List of maintainers for the eclass to be contacted. One line per
+ maintainer. Must start on a newline after the tag.
+
+
+
+
+ @AUTHOR:
+
+
+ YES
+
+
+ One or more name and email pairs.
+
+
+ List of authors for the eclass. One line per author. Must start on
+ a newline after the tag.
+
+
+
+
+ @BUGREPORTS:
+
+
+ YES
+
+
+ Multiline freetext.
+
+
+ Describes how bugs related to this eclass should be reported.
+
+
+
+
+ @VCSURL:
+
+
+ YES
+
+
+ A URI string.
+
+
+ Points to the URL of the VCS which contains the eclass source.
+
+
+
+
+ @BLURB:
+
+
+ NO
+
+
+ Single line freetext.
+
+
+ Contains a short description for the eclass. Must be on the same
+ line with the tag.
+
+
+
+
+ @DESCRIPTION:
+
+
+ YES
+
+
+ Multiline freetext.
+
+
+ Long description for the eclass.
+
+
+
+
+ @EXAMPLE:
+
+
+ YES
+
+
+ Multiline freetext.
+
+
+ Examples which illustrate various uses of this eclass.
+
+
+