Changeset 7933ed7


Ignore:
Timestamp:
08/13/2019 03:03:39 PM (5 years ago)
Author:
Pierre Labastie <pierre@…>
Branches:
ablfs-more, legacy, trunk
Children:
8fc6a47
Parents:
5451eae
Message:

Refactoring the output of installation instructions:

Create a template which processes the instruction tree fragment (only header
for now, the content is bogus), and call it from main sheet.

Location:
BLFS/xsl
Files:
1 edited
1 moved

Legend:

Unmodified
Added
Removed
  • BLFS/xsl/process-install.xsl

    r5451eae r7933ed7  
    44    version="1.0">
    55
    6 <!-- $Id$ -->
    7 
    8   <xsl:template match="screen" mode="installation">
    9     <xsl:param name="want-stats" select="false"/>
     6<!-- $Id: gen-install.xsl 4107 2019-06-15 15:26:23Z pierre $ -->
     7
     8  <xsl:template name="process-install">
     9    <xsl:param name="instruction-tree"/>
     10    <xsl:param name="want-stats"/>
     11    <xsl:param name="root-seen"/>
     12    <xsl:param name="install-seen"/>
     13    <xsl:param name="test-seen"/>
     14    <xsl:param name="doc-seen"/>
     15
    1016<!-- "nature" variables:
    1117      - 'non-root': executable as user
  • BLFS/xsl/scripts.xsl

    r5451eae r7933ed7  
    9090<!-- end parameters and global variables -->
    9191
    92 <!-- include the templates for the screen children of role="install" sect2 -->
    93   <xsl:include href="gen-install.xsl"/>
     92<!-- include the template for processing screen children of
     93     role="install" sect2 -->
     94  <xsl:include href="process-install.xsl"/>
    9495
    9596<!--=================== Begin processing ========================-->
     
    276277        </xsl:if>
    277278
    278         <xsl:apply-templates
    279              mode="installation"
     279        <xsl:call-template name="process-install">
     280          <xsl:with-param
     281             name="instruction-tree"
    280282             select=".//screen[not(@role = 'nodump') and ./userinput] |
    281283                     .//para/command[contains(text(),'check') or
    282                                      contains(text(),'test')]">
     284                                     contains(text(),'test')]"/>
    283285          <xsl:with-param name="want-stats" select="$want-stats"/>
    284         </xsl:apply-templates>
     286          <xsl:with-param name="root-seen" select="boolean(0)"/>
     287          <xsl:with-param name="install-seen" select="boolean(0)"/>
     288          <xsl:with-param name="test-seen" select="boolean(0)"/>
     289          <xsl:with-param name="doc-seen" select="boolean(0)"/>
     290        </xsl:call-template>
    285291        <xsl:text>
    286292</xsl:text>
Note: See TracChangeset for help on using the changeset viewer.