Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 50972 | Differences between
and this patch

Collapse All | Expand All

(-)cruisecontrol-2.2.1-orig/reporting/jsp/webcontent/css/cruisecontrol.css (+11 lines)
Lines 49-51 Link Here
49
.checkstyle-oddrow { background-color:#CCCCCC }
49
.checkstyle-oddrow { background-color:#CCCCCC }
50
.checkstyle-data { font-family:arial,helvetica,sans-serif; font-size:8pt; color:#000000; }
50
.checkstyle-data { font-family:arial,helvetica,sans-serif; font-size:8pt; color:#000000; }
51
.checkstyle-sectionheader { background-color:#000066; font-family:arial,helvetica,sans-serif; font-size:10pt; color:#FFFFFF; }
51
.checkstyle-sectionheader { background-color:#000066; font-family:arial,helvetica,sans-serif; font-size:10pt; color:#FFFFFF; }
52
53
.pmd-evenrow { font-family:arial,helvetica,sans-serif; font-size:8pt; color:#000000; background-color:#FFFFCC; }
54
.pmd-oddrow { font-family:arial,helvetica,sans-serif; font-size:8pt; color:#000000; background-color:#CCCCCC; }
55
.pmd-fileheader { background-color:#FFFFFF; font-family:arial,helvetica,sans-serif; font-size:9pt; color:#000000; }
56
.pmd-sectionheader { background-color:#000066; font-family:arial,helvetica,sans-serif; font-size:9pt; color:#FFFFFF; }
57
.pmd-priority-1 { background-color:#0000FF; }
58
.pmd-priority-2 { background-color:#08FFF0; }
59
.pmd-priority-3 { background-color:#CFFF00; }
60
.pmd-priority-4 { background-color:#FFFC00; }
61
.pmd-priority-5 { background-color:#FF0000; }
62
(-)cruisecontrol-2.2.1-orig/reporting/jsp/webcontent/xsl/buildresults.xsl (+2 lines)
Lines 40-45 Link Here
40
  <xsl:import href="maven.xsl"/>
40
  <xsl:import href="maven.xsl"/>
41
  <xsl:import href="nant.xsl"/>
41
  <xsl:import href="nant.xsl"/>
42
  <xsl:import href="checkstyle.xsl"/>
42
  <xsl:import href="checkstyle.xsl"/>
43
  <xsl:import href="pmd.xsl"/>
43
  <xsl:import href="errors.xsl"/>
44
  <xsl:import href="errors.xsl"/>
44
  <xsl:import href="compile.xsl"/>
45
  <xsl:import href="compile.xsl"/>
45
  <xsl:import href="javadoc.xsl"/>
46
  <xsl:import href="javadoc.xsl"/>
Lines 55-60 Link Here
55
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="maven"/></p>
56
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="maven"/></p>
56
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="nant"/></p>
57
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="nant"/></p>
57
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="checkstyle"/></p>
58
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="checkstyle"/></p>
59
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="pmd"/></p>
58
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="errors"/></p>
60
    <p><xsl:apply-templates select="$cruisecontrol.list" mode="errors"/></p>
59
    <!--
61
    <!--
60
      for traditional cc display of only compile errors and warnings
62
      for traditional cc display of only compile errors and warnings
(-)cruisecontrol-2.2.1-orig/reporting/jsp/webcontent/xsl/pmd.xsl (+76 lines)
Line 0 Link Here
1
<?xml version="1.0"?>
2
3
<!--
4
 - $Header$
5
 - 
6
 - XSL template for PMD results reporting inside of CruiseControl.
7
 - 
8
 - Copyright (C) 2005  Christopher G. Stach II <cgs@ldsys.net>
9
 - 
10
 - This program is free software; you can redistribute it and/or
11
 - modify it under the terms of the GNU General Public License
12
 - as published by the Free Software Foundation; either version 2
13
 - of the License, or (at your option) any later version.
14
 - 
15
 - This program is distributed in the hope that it will be useful,
16
 - but WITHOUT ANY WARRANTY; without even the implied warranty of
17
 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18
 - GNU General Public License for more details.
19
 - 
20
 - You should have received a copy of the GNU General Public License
21
 - along with this program; if not, write to the Free Software
22
 - Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
23
 -->
24
25
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
26
  <xsl:output method="html" />
27
28
  <xsl:template match="/" mode="pmd">
29
    <xsl:apply-templates select="cruisecontrol/pmd" mode="pmd" />
30
  </xsl:template>
31
32
  <xsl:template match="pmd[file/violation]" mode="pmd">
33
    <xsl:variable name="total.violation.count" select="count(file/violation)" />
34
    <table align="center" cellpadding="2" cellspacing="0" border="0" width="98%">
35
      <tr>
36
        <td class="pmd-sectionheader">PMD violations (<xsl:value-of select="$total.violation.count" />)</td>
37
      </tr>
38
      <tr>
39
        <td><table width="100%">
40
            <xsl:for-each select="file">
41
            <xsl:sort select="@name" />
42
            <tr class="pmd-fileheader">
43
              <td colspan="4"><xsl:value-of select="@name" /> (<xsl:value-of select="count(violation)" />)</td>
44
            </tr>
45
            <xsl:for-each select="violation">
46
            <xsl:sort select="@line" />
47
            <xsl:sort select="@priority" order="descending" />
48
            <tr>
49
              <xsl:if test="position() mod 2 = 0">
50
                <xsl:attribute name="class">pmd-evenrow</xsl:attribute>
51
              </xsl:if>
52
              <xsl:if test="position() mod 2 = 1">
53
                <xsl:attribute name="class">pmd-oddrow</xsl:attribute>
54
              </xsl:if>
55
              <td width="10">
56
                <xsl:attribute name="class">pmd-priority-<xsl:value-of select="@priority" /></xsl:attribute>
57
                &#xA0;
58
              </td>
59
              <td>Line <xsl:value-of select="@line" /></td>
60
              <td><xsl:value-of select="text()" /></td>
61
              <td><xsl:value-of select="@ruleset" /></td>
62
              <td><xsl:value-of select="@rule" /></td>
63
            </tr>
64
            </xsl:for-each>
65
            </xsl:for-each>
66
          </table></td>
67
      </tr>
68
    </table>
69
  </xsl:template>
70
71
  <xsl:template match="/">
72
    <xsl:apply-templates select="." mode="pmd" />
73
  </xsl:template>
74
75
</xsl:stylesheet>
76

Return to bug 50972