Tweak asciidoc output to work with broken docbook-xsl
docbook-xsl v1.68 incorrectly converts "<screen>" from docbook to manpage by not rendering it verbatim. v1.69 handles it correctly, but not many current popular distributions ship with it. asciidoc by default converts "listingblock" to "<screen>". This change causes asciidoc in git to convert "listingblock" to "<literallayout>", which both old and new docbook-xsl handle correctly. The difference can be seen in any manpage which includes a multi-line example, such as git-branch. [jc: the original patch was an disaster for html backends, so I made it apply only to docbook backends. ] Signed-off-by: Junio C Hamano <junkio@cox.net>
Francis Daly committed
Mar 5, 2006 at 23:13 UTC
e920b5655719bee9c98a3d7d3b05ac6e8cf9d176
1 file changed
+10
Documentation/asciidoc.conf
+10
@@ -18,6 +18,16 @@ ifdef::backend-docbook[]
18
{0#</citerefentry>}
19
endif::backend-docbook[]
20
21
+ifdef::backend-docbook[]
22
+# "unbreak" docbook-xsl v1.68 for manpages. v1.69 works with or without this.
23
+[listingblock]
24
+<example><title>{title}</title>
25
+<literallayout>
26
+|
27
+</literallayout>
28
+{title#}</example>
29
+endif::backend-docbook[]
30
+
31
ifdef::backend-xhtml11[]
32
[gitlink-inlinemacro]
33
<a href="{target}.html">{target}{0?({0})}</a>