Added stylesheet which converts manrefs to docbook book content.
authorAdam Dickmeiss <adam@indexdata.dk>
Thu, 20 Apr 2006 12:10:50 +0000 (12:10 +0000)
committerAdam Dickmeiss <adam@indexdata.dk>
Thu, 20 Apr 2006 12:10:50 +0000 (12:10 +0000)
Makefile.am
ref2dbinc.xsl [new file with mode: 0644]

index c15b1cd..fabb034 100644 (file)
@@ -1,11 +1,12 @@
-## $Id: Makefile.am,v 1.3 2006-04-20 11:46:15 adam Exp $
+## $Id: Makefile.am,v 1.4 2006-04-20 12:10:50 adam Exp $
 
 commondir=$(datadir)/doc/@PACKAGE@/common
 
 common_DATA = style1.css id.png
 
 SUPPORTFILES = \
- id.eps \
+ id.eps \ 
+ ref2dbinc.xsl \
  html.dsl html.dsl.in \
  html.xsl html.xsl.in \
  tkl.xsl tkl.xsl.in \
diff --git a/ref2dbinc.xsl b/ref2dbinc.xsl
new file mode 100644 (file)
index 0000000..764899c
--- /dev/null
@@ -0,0 +1,38 @@
+<?xml version="1.0"?>
+<!-- $Id: ref2dbinc.xsl,v 1.1 2006-04-20 12:10:50 adam Exp $ -->
+<xsl:stylesheet
+  xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+  version="1.0">
+
+    <xsl:output method="xml" encoding="UTF-8"/>
+
+<xsl:template match="/refentry">
+  <section>
+    <title>
+      <xsl:value-of select="refmeta/refentrytitle"/>
+    </title>
+    <xsl:apply-templates/>
+  </section>
+</xsl:template>
+
+<xsl:template match="refnamediv">
+  <para>
+     <xsl:value-of select="refpurpose"/> 
+  </para>
+</xsl:template>
+
+<xsl:template match="refmeta">
+</xsl:template>
+
+<xsl:template match="refsynopsisdiv">
+  <xsl:copy-of select="cmdsynopsis"/>
+</xsl:template>
+
+<xsl:template match="refsect1">
+ <section>
+  <xsl:copy-of select="*"/>
+ </section>
+</xsl:template>
+
+</xsl:stylesheet>
+