<commit_before><?xml version="1.0"?>

<xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:lenya="http://apache.org/cocoon/lenya/publication/1.0"
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:xhtml="http://www.w3.org/1999/xhtml"
    xmlns:page="http://apache.org/cocoon/lenya/cms-page/1.0"
    >

<xsl:template match="lenya:lenya">
  <page:page>
    
  <page:title>Apache Lenya - Content Management System</page:title>
  <page:body>
    <xsl:apply-templates select="xhtml:div[@class = 'lenya-frontpage']"/>
    <xsl:apply-templates select="lenya:publications"/>
  </page:body>
  </page:page>
</xsl:template>

<xsl:template match="lenya:publications">
<div class="lenya-sidebar">
<!--<div class="lenya-padding">-->
<div class="lenya-sidebar-heading">Publications</div>
<!--
<p>
We are working on a catalog of sample publications. The idea is that an
"integrator" can pull out an appropriate publication and reuse it for building
efficiently its own publication. The <a href="docs/tutorial/index.html">tutorial</a> describes how to do that.
</p>
-->
<xsl:for-each select="lenya:publication">
  <xsl:choose>
    <xsl:when test="lenya:XPSEXCEPTION">
      <div class="lenya-publication-item">
        <font color="red">Exception:</font>
        (publication id = <xsl:value-of select="@pid"/>) <xsl:value-of select="lenya:XPSEXCEPTION"/>
      </div>
    </xsl:when>
    <xsl:otherwise>
      <xsl:choose>
        <xsl:when test="lenya:publication/@lenya:show = 'false'">
          <!-- do not list this publication. Might be a "template" publication -->
        </xsl:when>
        <xsl:otherwise>
          <div class="lenya-publication-item">
            <a href="{@pid}/introduction.html">
            <xsl:apply-templates select="lenya:publication/lenya:name"/></a>
          </div>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:otherwise>
  </xsl:choose>
</xsl:for-each>
<!--</div>-->
</div>
</xsl:template>

<xsl:template match="@*|node()">
  <xsl:copy><xsl:apply-templates select="@*|node()"/></xsl:copy>
</xsl:template>

</xsl:stylesheet>
<commit_msg>do not show exception re prune<commit_after><?xml version="1.0"?>

<xsl:stylesheet version="1.0"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
    xmlns:lenya="http://apache.org/cocoon/lenya/publication/1.0"
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:xhtml="http://www.w3.org/1999/xhtml"
    xmlns:page="http://apache.org/cocoon/lenya/cms-page/1.0"
    >

<xsl:template match="lenya:lenya">
  <page:page>
    
  <page:title>Apache Lenya - Content Management System</page:title>
  <page:body>
    <xsl:apply-templates select="xhtml:div[@class = 'lenya-frontpage']"/>
    <xsl:apply-templates select="lenya:publications"/>
  </page:body>
  </page:page>
</xsl:template>

<xsl:template match="lenya:publications">
<div class="lenya-sidebar">
<!--<div class="lenya-padding">-->
<div class="lenya-sidebar-heading">Publications</div>
<!--
<p>
We are working on a catalog of sample publications. The idea is that an
"integrator" can pull out an appropriate publication and reuse it for building
efficiently its own publication. The <a href="docs/tutorial/index.html">tutorial</a> describes how to do that.
</p>
-->
<xsl:for-each select="lenya:publication">
  <xsl:choose>
    <xsl:when test="lenya:XPSEXCEPTION">
<!--
      <div class="lenya-publication-item">
        <font color="red">Exception:</font>
        (publication id = <xsl:value-of select="@pid"/>) <xsl:value-of select="lenya:XPSEXCEPTION"/>
      </div>
-->
    </xsl:when>
    <xsl:otherwise>
      <xsl:choose>
        <xsl:when test="lenya:publication/@lenya:show = 'false'">
          <!-- do not list this publication. Might be a "template" publication -->
        </xsl:when>
        <xsl:otherwise>
          <div class="lenya-publication-item">
            <a href="{@pid}/introduction.html">
            <xsl:apply-templates select="lenya:publication/lenya:name"/></a>
          </div>
        </xsl:otherwise>
      </xsl:choose>
    </xsl:otherwise>
  </xsl:choose>
</xsl:for-each>
<!--</div>-->
</div>
</xsl:template>

<xsl:template match="@*|node()">
  <xsl:copy><xsl:apply-templates select="@*|node()"/></xsl:copy>
</xsl:template>

</xsl:stylesheet>

{'fraction_non_alphanumeric': 0.19430051813471502, 'fraction_numerical': 0.010833725859632595, 'mean_word_length': 3.6466083150984683, 'pattern_counts': {'":': 0, '<': 122, '<?xml version=': 2, '>': 122, 'https://': 0, 'lorem ipsum': 0, 'www.': 6, 'xml': 12}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '657689', 'n_tokens_mistral': 1591, 'n_tokens_neox': 1454, 'n_words': 263}