You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by di...@apache.org on 2003/01/01 10:50:37 UTC
cvs commit: jakarta-turbine-maven/src/plugins-build/xdoc site.jsl
dion 2003/01/01 01:50:36
Modified: src/plugins-build/xdoc site.jsl
Log:
Put back missing goals/changelog etc templates.
Still missing the file activity report somehow...
Revision Changes Path
1.17 +112 -1 jakarta-turbine-maven/src/plugins-build/xdoc/site.jsl
Index: site.jsl
===================================================================
RCS file: /home/cvs/jakarta-turbine-maven/src/plugins-build/xdoc/site.jsl,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -r1.16 -r1.17
--- site.jsl 31 Dec 2002 07:14:17 -0000 1.16
+++ site.jsl 1 Jan 2003 09:50:36 -0000 1.17
@@ -113,7 +113,6 @@
</j:if>
<!-- render links -->
<x:if select="$nav/body/links">
- <!-- FIXME: need to test/implement -->
<jsl:applyTemplates select="$nav/body/links"/>
</x:if>
<x:if select="not($nav/body/links)">
@@ -318,6 +317,11 @@
<div class="app">
<!-- FIXME really shouldn't use $doc, but jelly loses it's context again -->
<jsl:applyTemplates select="$doc/document/body/section"/>
+ <jsl:applyTemplates select="$doc/document/body/glossary" />
+ <jsl:applyTemplates select="$doc/document/body/release" />
+ <jsl:applyTemplates select="$doc/document/body/changelog" />
+ <jsl:applyTemplates select="$doc/document/body/taskList" />
+ <jsl:applyTemplates select="$doc/document/body/goals" />
</div>
</div>
</td>
@@ -456,6 +460,113 @@
<jsl:applyTemplates select="*"/>
</x:element>
</jsl:template>
+
+ <!--************************-->
+ <!-- glossary documentation -->
+ <!--************************-->
+ <jsl:template match="glossary" trim="false">
+ <jsl:applyTemplates select="glossary-entries/glossary-entry" />
+ </jsl:template>
+
+ <jsl:template match="glossary-entry" trim="false">
+ <strong><x:expr select="name" /></strong>
+ <br/>
+ <x:expr select="definition" />
+ <p/>
+ </jsl:template>
+
+ <!--************************-->
+ <!-- goals documentation -->
+ <!--************************-->
+ <jsl:template match="goals" trim="false">
+ <!-- reset row alternation -->
+ <j:set var="rowMode" value="" />
+ <div class="h3">
+ <h3><a name="Goals">Goals</a></h3>
+ <table>
+ <tr width='100%'><th>Goal</th><th>Description</th></tr>
+ <jsl:applyTemplates select="goal"/>
+ </table>
+ </div>
+ </jsl:template>
+
+ <!-- a goal -->
+ <!-- FIXME: this is copied from tr - there must be a way of
+ calling templates in jsl? -->
+ <jsl:template match="goal" trim="false">
+ <j:choose>
+ <j:when test="${rowMode == 'a'}">
+ <j:set var="rowMode" value="b"/>
+ </j:when>
+ <j:otherwise>
+ <j:set var="rowMode" value="a"/>
+ </j:otherwise>
+ </j:choose>
+ <x:element name="tr"><x:attribute name="class">${rowMode}</x:attribute>
+
+ <!-- copy attributes -->
+ <x:forEach select="@*">
+ <x:set var="attr" value="."/>
+ <x:attribute name="${attr.name}">${attr.text}</x:attribute>
+ </x:forEach>
+ <j:set var="_goalName"><x:expr select="./name" /></j:set>
+ <td width='20%'><a name="${_goalName}">${_goalName}</a></td>
+ <td width='80%'><jsl:applyTemplates select="description" /></td>
+ </x:element>
+ </jsl:template>
+
+ <jsl:template match="description">
+ <x:expr select="."/>
+ </jsl:template>
+
+ <!--************************-->
+ <!-- changelog documentation-->
+ <!--************************-->
+ <jsl:template match="changelog" trim="false">
+ <j:set var="rowMode" value="" />
+ <table width="100%">
+ <tr>
+ <th>Date</th><th>Author</th><th>Files/Message</th>
+ </tr>
+ <jsl:applyTemplates select="changelog-entry" />
+ </table>
+ </jsl:template>
+
+ <!-- transform a changelog entry -->
+ <!-- FIXME: tr code copied from above -->
+ <jsl:template match="changelog-entry" trim="false">
+ <j:choose>
+ <j:when test="${rowMode == 'a'}">
+ <j:set var="rowMode" value="b"/>
+ </j:when>
+ <j:otherwise>
+ <j:set var="rowMode" value="a"/>
+ </j:otherwise>
+ </j:choose>
+ <x:element name="tr"><x:attribute name="class">${rowMode}</x:attribute>
+
+ <!-- copy attributes -->
+ <x:forEach select="@*">
+ <x:set var="attr" value="."/>
+ <x:attribute name="${attr.name}">${attr.text}</x:attribute>
+ </x:forEach>
+
+ <td><x:expr select="date" /> <x:expr select="time" /></td>
+ <td><x:expr select="author"/></td>
+ <td><jsl:applyTemplates select="file" />
+ <pre><x:expr select="msg"/></pre>
+ </td>
+ </x:element>
+ </jsl:template>
+
+ <jsl:template match="file">
+ <j:set var="url">${pom.repository.url}<x:expr select="name"/></j:set>
+ <j:set var="revUrl">${url}?<x:expr select="revision"/>&content-type=text/vnd.viewcvs-markup</j:set>
+ <a href="${url}"><x:expr select="name"/></a> -
+ <a href="${revUrl}">v<x:expr select="revision"/></a>
+ <br/>
+ </jsl:template>
+
<!-- copy any other elements through -->
<jsl:template match="*" trim="false">