Add a "version" parameter to bump.xsl

This commit is contained in:
Pierre Labastie 2012-03-05 17:33:11 +00:00
parent 6631b83ab8
commit 18a2beaa27

View file

@ -7,6 +7,19 @@
<xsl:param name="packages" select="'packages.xml'"/>
<xsl:param name="package" select="''"/>
<xsl:param name="version" select="'N'"/>
<xsl:variable name="vers">
<xsl:choose>
<xsl:when test="$version='N'">
<xsl:value-of select=
"document($packages)//package[string(name)=$package]/version"/>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="$version"/>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:output
method="xml"
@ -20,9 +33,7 @@
<xsl:if test="not(.//package[string(name)=$package])">
<package>
<name><xsl:value-of select="$package"/></name>
<version><xsl:value-of select=
"document($packages)//package[string(name)=$package]/version"/>
</version>
<version><xsl:value-of select="$vers"/></version>
</package>
</xsl:if>
</sublist>
@ -33,9 +44,7 @@
<xsl:when test="string(name)=$package">
<package>
<name><xsl:value-of select="name"/></name>
<version><xsl:value-of select=
"document($packages)//package[string(name)=$package]/version"/>
</version>
<version><xsl:value-of select="$vers"/></version>
</package>
</xsl:when>
<xsl:otherwise>