]> git.ipfire.org Git - people/stevee/network.git/commitdiff
man: Use asciidoc to generate HTML pages directly
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 26 Sep 2018 21:04:35 +0000 (23:04 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Sun, 31 Mar 2019 12:47:04 +0000 (14:47 +0200)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
Makefile.am
man/custom-html.xsl [deleted file]

index d01e22333f0c851ab5593977a60278102232ce90..c4f8b453e5ddcb86d2f3582dba090734cf3d86c2 100644 (file)
@@ -494,8 +494,7 @@ CLEANFILES += \
        $(MANPAGES_HTML)
 
 EXTRA_DIST += \
-       $(MANPAGES_TXT) \
-       man/custom-html.xsl
+       $(MANPAGES_TXT)
 
 XSLTPROC_FLAGS = \
        --nonet \
@@ -509,17 +508,14 @@ XSLTPROC_COMMAND_MAN = \
        $(AM_V_XSLT)$(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) \
                http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
 
-XSLTPROC_COMMAND_HTML = \
-       $(AM_V_XSLT)$(XSLTPROC) -o $@ $(XSLTPROC_FLAGS) $(srcdir)/man/custom-html.xsl $<
-
 man/%.xml: man/%.txt
        $(AM_V_ASCIIDOC)$(ASCIIDOC) -d manpage -b docbook -o $@ $<
 
 man/%.8: man/%.xml
        $(XSLTPROC_COMMAND_MAN)
 
-man/%.html: man/%.xml man/custom-html.xsl
-       $(XSLTPROC_COMMAND_HTML)
+man/%.html: man/%.txt
+       $(AM_V_ASCIIDOC)$(ASCIIDOC) -b html5 -a icons -a theme=flask -o $@ $<
 
 # ------------------------------------------------------------------------------
 
diff --git a/man/custom-html.xsl b/man/custom-html.xsl
deleted file mode 100644 (file)
index fe2b54e..0000000
+++ /dev/null
@@ -1,31 +0,0 @@
-<?xml version='1.0'?>
-
-<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
-
-<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/html/docbook.xsl"/>
-
-<!-- translate man page references to links to html pages -->
-<xsl:template match="citerefentry">
-  <a>
-    <xsl:attribute name="href">
-      <xsl:value-of select="refentrytitle"/><xsl:text>.html</xsl:text>
-    </xsl:attribute>
-    <xsl:call-template name="inline.charseq"/>
-  </a>
-</xsl:template>
-
-<!-- add Index link at top of page -->
-<xsl:template name="user.header.content">
-  <a>
-    <xsl:attribute name="href">
-      <xsl:text>index.html</xsl:text>
-    </xsl:attribute>
-    <xsl:text>Index</xsl:text>
-  </a>
-  <hr/>
-</xsl:template>
-
-<!-- Switch things to UTF-8, ISO-8859-1 is soo yesteryear -->
-<xsl:output method="html" encoding="UTF-8" indent="no"/>
-
-</xsl:stylesheet>