log.xsl revision 0
2842N/A<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
3177N/A<xsl:output method="html" indent="yes" encoding="US-ASCII"/>
3177N/A<!--
3177N/A Copyright 2000-2004 The Apache Software Foundation
3177N/A
3177N/A Licensed under the Apache License, Version 2.0 (the "License");
3177N/A you may not use this file except in compliance with the License.
3177N/A You may obtain a copy of the License at
3177N/A
3177N/A http://www.apache.org/licenses/LICENSE-2.0
3177N/A
3177N/A Unless required by applicable law or agreed to in writing, software
3177N/A distributed under the License is distributed on an "AS IS" BASIS,
3177N/A WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
3177N/A See the License for the specific language governing permissions and
3177N/A limitations under the License.
3177N/A
3177N/A-->
3177N/A
3177N/A<!--
3177N/A
3177N/A The purpose have this XSL is to provide a nice way to look at the output
3177N/A from the Ant XmlLogger (ie: ant -listener org.apache.tools.ant.XmlLogger )
3177N/A
3215N/A @author <a href="mailto:sbailliez@apache.org">Stephane Bailliez</a>
5621N/A
3177N/A-->
2842N/A<xsl:decimal-format decimal-separator="." grouping-separator="," />
2842N/A
2842N/A<xsl:template match="/">
2842N/A<html>
2842N/A <head>
2842N/A <style type="text/css">
2842N/A .bannercell {
2842N/A border: 0px;
2842N/A padding: 0px;
2842N/A }
2842N/A body {
2842N/A margin: 0;
2842N/A font:normal 100% arial,helvetica,sanserif;
2909N/A background-color:#FFFFFF;
2842N/A color:#000000;
2842N/A }
2842N/A table.status {
2842N/A font:bold 80% arial,helvetica,sanserif;
2909N/A background-color:#525D76;
2909N/A color:#ffffff;
2842N/A }
2842N/A table.log tr td, tr th {
2842N/A font-size: 80%;
2842N/A }
2909N/A .error {
2909N/A color:red;
2909N/A }
2909N/A .warn {
2909N/A color:brown;
2909N/A }
4225N/A .info {
2909N/A color:gray;
2909N/A }
5621N/A .debug{
2909N/A color:gray;
2909N/A }
2909N/A .failed {
2909N/A font-size:80%;
2909N/A background-color: red;
2909N/A color:#FFFFFF;
2909N/A font-weight: bold
2909N/A }
2909N/A .complete {
5621N/A font-size:80%;
2909N/A background-color: #525D76;
2909N/A color:#FFFFFF;
2909N/A font-weight: bold
2909N/A }
2909N/A .a td {
2909N/A background: #efefef;
2909N/A }
2909N/A .b td {
2909N/A background: #fff;
2909N/A }
2909N/A th, td {
2842N/A text-align: left;
2842N/A vertical-align: top;
2842N/A }
2842N/A th {
2842N/A background: #ccc;
2842N/A color: black;
2842N/A }
2842N/A table, th, td {
2842N/A border: none
2909N/A }
2909N/A h3 {
2909N/A font:bold 80% arial,helvetica,sanserif;
2909N/A background: #525D76;
2909N/A color: white;
2909N/A text-decoration: none;
2909N/A padding: 5px;
2909N/A margin-right: 2px;
2909N/A margin-left: 2px;
2909N/A margin-bottom: 0;
2909N/A }
2909N/A </style>
2909N/A </head>
2909N/A <body>
2909N/A <!-- jakarta logo -->
2909N/A <table border="0" cellpadding="0" cellspacing="0" width="100%">
2909N/A <tr>
2909N/A <td valign="top" class="bannercell">
2909N/A <a href="http://jakarta.apache.org/">
2909N/A <img src="http://jakarta.apache.org/images/jakarta-logo.gif" alt="http://jakarta.apache.org" align="left" border="0"/>
2909N/A </a>
2909N/A </td>
2909N/A <td style="text-align:right;vertical-align:bottom">
2909N/A <a href="http://jakarta.apache.org/ant">Apache Ant</a>
2909N/A </td>
2909N/A </tr>
2909N/A </table>
2909N/A
2909N/A <table border="0" width="100%">
2909N/A <tr><td><hr noshade="yes" size="1"/></td></tr>
2909N/A </table>
2909N/A
2909N/A <xsl:apply-templates select="build"/>
2909N/A
2909N/A <!-- FOOTER -->
2909N/A <table width="100%">
2909N/A <tr><td><hr noshade="yes" size="1"/></td></tr>
2909N/A <tr><td>
2909N/A <div align="center"><font color="#525D76" size="-1"><em>
2909N/A Copyright &#169; 2000-2002, Apache Software Foundation
2909N/A </em></font></div>
2909N/A </td></tr>
2909N/A </table>
2909N/A </body>
2909N/A</html>
2909N/A</xsl:template>
2909N/A
2909N/A<xsl:template match="build">
2909N/A <!-- build status -->
2909N/A <table width="100%">
2909N/A <xsl:attribute name="class">
2909N/A <xsl:if test="@error">failed</xsl:if>
2909N/A <xsl:if test="not(@error)">complete</xsl:if>
2909N/A </xsl:attribute>
2909N/A <tr>
2909N/A <xsl:if test="@error">
2909N/A <td nowrap="yes">Build Failed</td>
2909N/A </xsl:if>
2909N/A <xsl:if test="not(@error)">
2909N/A <td nowrap="yes">Build Complete</td>
2909N/A </xsl:if>
2909N/A <td style="text-align:right" nowrap="yes">Total Time: <xsl:value-of select="@time"/></td>
2909N/A </tr>
2909N/A <tr>
2909N/A <td colspan="2">
2909N/A <xsl:if test="@error">
2909N/A <tt><xsl:value-of select="@error"/></tt><br/>
2909N/A <i style="font-size:80%">See the <a href="#stacktrace" alt="Click for details">stacktrace</a>.</i>
2909N/A </xsl:if>
2909N/A </td>
2909N/A </tr>
2909N/A </table>
2909N/A <table border="1" cellspacing="2" cellpadding="3" width="100%" style="font-size:80%">
2909N/A <tr class="a"><td width="1">ant.file</td><td><xsl:value-of select="substring-after(//message[contains(text(),'ant.file')], '->')"/></td></tr>
2909N/A <tr class="b"><td width="1">ant.version</td><td><xsl:value-of select="substring-after(//message[contains(text(),'ant.version')], '->')"/></td></tr>
2909N/A <tr class="a"><td width="1">java.version</td><td><xsl:value-of select="substring-after(//message[contains(text(),'java.vm.version')], '->')"/></td></tr>
2909N/A <tr class="b"><td width="1">os.name</td><td><xsl:value-of select="substring-after(//message[contains(text(),'os.name')], '->')"/></td></tr>
2909N/A </table>
2909N/A <!-- build information -->
2909N/A <h3>Build events</h3>
2909N/A <table class="log" border="1" cellspacing="2" cellpadding="3" width="100%">
2909N/A <tr>
2909N/A <th nowrap="yes" align="left" width="1%">target</th>
2909N/A <th nowrap="yes" align="left" width="1%">task</th>
2909N/A <th nowrap="yes" align="left">message</th>
2909N/A </tr>
2909N/A <xsl:apply-templates select=".//message[@priority != 'debug']"/>
2909N/A </table>
2909N/A <p>
2909N/A <!-- stacktrace -->
2909N/A <xsl:if test="stacktrace">
2909N/A <a name="stacktrace"/>
2909N/A <h3>Error details</h3>
2909N/A <table width="100%">
2909N/A <tr><td>
2909N/A <pre><xsl:value-of select="stacktrace"/></pre>
2909N/A </td></tr>
2909N/A </table>
2909N/A </xsl:if>
2909N/A </p>
2909N/A</xsl:template>
2909N/A
2909N/A<!-- report every message but those with debug priority -->
2909N/A<xsl:template match="message[@priority!='debug']">
2909N/A <tr valign="top">
2909N/A <!-- alternated row style -->
2909N/A <xsl:attribute name="class">
2909N/A <xsl:if test="position() mod 2 = 1">a</xsl:if>
2909N/A <xsl:if test="position() mod 2 = 0">b</xsl:if>
2909N/A </xsl:attribute>
2909N/A <td nowrap="yes" width="1%"><xsl:value-of select="../../@name"/></td>
2909N/A <td nowrap="yes" style="text-align:right" width="1%">[ <xsl:value-of select="../@name"/> ]</td>
2909N/A <td class="{@priority}" nowrap="yes">
2909N/A <xsl:value-of select="text()"/>
2909N/A </td>
2909N/A </tr>
2909N/A</xsl:template>
2909N/A
2909N/A</xsl:stylesheet>
2909N/A