[pypy-svn] r71459 - in pypy/build/bot2: codespeak-html pypybuildbot

fijal at codespeak.net fijal at codespeak.net
Wed Feb 24 18:07:45 CET 2010


Author: fijal
Date: Wed Feb 24 18:07:44 2010
New Revision: 71459

Added:
   pypy/build/bot2/codespeak-html/summary.css
Modified:
   pypy/build/bot2/codespeak-html/buildbot.css
   pypy/build/bot2/pypybuildbot/summary.py
Log:
A hack to try to have different CSS for summary. Thanks to Brian Warner it did
not take the whole day


Modified: pypy/build/bot2/codespeak-html/buildbot.css
==============================================================================
--- pypy/build/bot2/codespeak-html/buildbot.css	(original)
+++ pypy/build/bot2/codespeak-html/buildbot.css	Wed Feb 24 18:07:44 2010
@@ -380,41 +380,3 @@
 table.Grid tr td.build {
         border: 1px gray solid;
 }
-
-/* failure summary */
-.failSummary.success {
-    color: #408000;
-    background-color: #ffffff;
-    font-weight: bold;
-}
-
-.failSummary.failed {
-    color: #E00000;
-    font-weight: bold;
-}
-
-a.failSummary.failed {
-    color: #E00000;
-    font-weight: bold;
-}
-
-a:visited.failSummary.failed {
-    color: #E0B000;
-    font-weight: bold;
-}
-
-a.failSummary.branch, a:visited.failSummary.branch { 
-    color: black;
-}
-
-a.failSummary.trunkVsAny, a:visited.failSummary.trunkVsAny { 
-    color: #a9a9a9;
-}
-
-a.failSummary.builderquery, a:visited.failSummary.builderquery {
-    color: black;
-}
-
-a.failSummary.builder, a:visited.failSummary.builder {
-    color: grey;
-}

Added: pypy/build/bot2/codespeak-html/summary.css
==============================================================================
--- (empty file)
+++ pypy/build/bot2/codespeak-html/summary.css	Wed Feb 24 18:07:44 2010
@@ -0,0 +1,116 @@
+a:visited {
+	color: #800080;
+}
+
+td.Event, td.BuildStep, td.Activity, td.Change, td.Time, td.Builder {
+    border-top: 1px solid;
+    border-right: 1px solid;
+}
+
+td.box {
+       border: 1px solid;
+}
+
+/* Activity states */
+.offline { 
+        background-color: gray;
+}
+.idle {
+	background-color: white;
+}
+.waiting { 
+        background-color: yellow;
+}
+.building { 
+        background-color: yellow;
+}
+
+/* LastBuild, BuildStep states */
+.success {
+	background-color: #72ff75;
+}
+.failure {
+	background-color: red;
+}
+.warnings {
+	background-color: #ff8000;
+}
+.exception {
+	background-color: #c000c0;
+}
+.start,.running {
+	background-color: yellow;
+}
+
+/* grid styles */
+
+table.Grid {
+    border-collapse: collapse;
+}
+
+table.Grid tr td {
+    padding: 0.2em;
+    margin: 0px;
+    text-align: center;
+}
+
+table.Grid tr td.title {
+    font-size: 90%;
+    border-right: 1px gray solid;
+    border-bottom: 1px gray solid;
+}
+
+table.Grid tr td.sourcestamp {
+    font-size: 90%;
+}
+
+table.Grid tr td.builder {
+    text-align: right;
+    font-size: 90%;
+}
+
+table.Grid tr td.build {
+    border: 1px gray solid;
+}
+
+div.footer {
+    font-size: 80%;
+}
+
+/* failure summary */
+.failSummary.success {
+    color: #408000;
+    background-color: #ffffff;
+    font-weight: bold;
+}
+
+.failSummary.failed {
+    color: #E00000;
+    font-weight: bold;
+}
+
+a.failSummary.failed {
+    color: #E00000;
+    font-weight: bold;
+}
+
+a:visited.failSummary.failed {
+    color: #E0B000;
+    font-weight: bold;
+}
+
+a.failSummary.branch, a:visited.failSummary.branch { 
+    color: black;
+}
+
+a.failSummary.trunkVsAny, a:visited.failSummary.trunkVsAny { 
+    color: #a9a9a9;
+}
+
+a.failSummary.builderquery, a:visited.failSummary.builderquery {
+    color: black;
+}
+
+a.failSummary.builder, a:visited.failSummary.builder {
+    color: grey;
+}

Modified: pypy/build/bot2/pypybuildbot/summary.py
==============================================================================
--- pypy/build/bot2/pypybuildbot/summary.py	(original)
+++ pypy/build/bot2/pypybuildbot/summary.py	Wed Feb 24 18:07:44 2010
@@ -587,6 +587,11 @@
     except ValueError:
         return None
 
+HEAD_ELEMENTS = [
+    '<title>%(title)s</title>',
+    '<link href="%(root)ssummary.css" rel="stylesheet" type="text/css" />',
+    ]
+
 class Summary(HtmlResource):
 
     def __init__(self, categories=[], branch_order_prefixes=[]):
@@ -596,6 +601,14 @@
         self.categories = categories
         self.branch_order_prefixes = branch_order_prefixes
 
+    def content(self, request):
+        old_head_elements = request.site.buildbot_service.head_elements
+        self.head_elements = HEAD_ELEMENTS
+        try:
+            return HtmlResource.content(self, request)
+        finally:
+            request.site.buildbot_service.head_elements = old_head_elements
+
     def getTitle(self, request):
         status = self.getStatus(request)        
         return "%s: summaries of last %d revisions" % (status.getProjectName(),



More information about the Pypy-commit mailing list