diff options
author | Dan Nichilson <dnicholson@linuxfromscratch.org> | 2007-07-20 22:55:28 +0000 |
---|---|---|
committer | Dan Nichilson <dnicholson@linuxfromscratch.org> | 2007-07-20 22:55:28 +0000 |
commit | 85117fe2b9fa404a21083ba975e06b57a6866d1b (patch) | |
tree | 4194e280bb07f000c9bb49c4f645e8789c5f2af2 | |
parent | 479f92f627772b1964fa02b545c387f848562fce (diff) |
Cleanup newline generation in dump-commands
git-svn-id: http://svn.linuxfromscratch.org/LFS/trunk/BOOK@8225 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689
-rw-r--r-- | stylesheets/dump-commands.xsl | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/stylesheets/dump-commands.xsl b/stylesheets/dump-commands.xsl index e3cac13b7..9e2af96e4 100644 --- a/stylesheets/dump-commands.xsl +++ b/stylesheets/dump-commands.xsl @@ -6,6 +6,10 @@ <!-- XSLT stylesheet to extract commands from [B,H]LFS books. --> + <xsl:variable name="newline"> + <xsl:text>
</xsl:text> + </xsl:variable> + <xsl:template match="/"> <xsl:apply-templates select="//sect1"/> </xsl:template> @@ -47,31 +51,31 @@ <xsl:if test="child::* = userinput"> <xsl:choose> <xsl:when test="@role = 'root'"> - <xsl:text>
</xsl:text> <xsl:text># Run this as root</xsl:text> + <xsl:value-of select="$newline"/> <xsl:apply-templates select="userinput"/> <xsl:text># End root commands</xsl:text> - <xsl:text>
</xsl:text> + <xsl:value-of select="$newline"/> </xsl:when> <xsl:otherwise> <xsl:apply-templates select="userinput"/> </xsl:otherwise> </xsl:choose> + <xsl:value-of select="$newline"/> </xsl:if> </xsl:template> <xsl:template match="userinput"> - <xsl:text>
</xsl:text> <xsl:if test=".//replaceable"> <xsl:text># This block must be edited to suit your needs.</xsl:text> + <xsl:value-of select="$newline"/> </xsl:if> - <xsl:text>
</xsl:text> <xsl:apply-templates/> - <xsl:text>
</xsl:text> + <xsl:value-of select="$newline"/> <xsl:if test=".//replaceable"> <xsl:text># End of editable block.</xsl:text> + <xsl:value-of select="$newline"/> </xsl:if> - <xsl:text>
</xsl:text> </xsl:template> <xsl:template match="replaceable"> |