| OLD | NEW |
| 1 {{define "title"}}{{.Build.Summary.Label}}{{end}} | 1 {{define "title"}}{{.Build.Summary.Label}}{{end}} |
| 2 | 2 |
| 3 {{define "head"}}{{end}} | 3 {{define "head"}}{{end}} |
| 4 | 4 |
| 5 {{define "body"}} | 5 {{define "body"}} |
| 6 <div class="content"> | 6 <div class="content"> |
| 7 <h1>{{.Build.Summary.Label}}</h1> | 7 <h1>{{.Build.Summary.Label}}</h1> |
| 8 | 8 |
| 9 <div class="column"> | 9 <div class="column"> |
| 10 | 10 |
| 11 <h2>Results:</h2> | 11 <h2>Results:</h2> |
| 12 {{ with .Build.Summary }} | 12 {{ with .Build.Summary }} |
| 13 {{ if eq .Status.String "Running" }} | 13 {{ if eq .Status.String "Running" }} |
| 14 <p class="running result">Build Running | 14 <p class="running result">Build Running |
| 15 {{ else if eq .Status.String "Success" }} | 15 {{ else if eq .Status.String "Success" }} |
| 16 <p class="success result">Build Successful | 16 <p class="success result">Build Successful |
| 17 {{ else if eq .Status.String "InfraFailure" }} | 17 {{ else if eq .Status.String "InfraFailure" }} |
| 18 <p class="exception result">Internal Failure | 18 <p class="exception result">Internal Failure |
| 19 {{ else if eq .Status.String "Failure" }} | 19 {{ else if eq .Status.String "Failure" }} |
| 20 <p class="failure result">Build Failed | 20 <p class="failure result">Build Failed |
| 21 {{ else if eq .Status.String "NotRun" }} |
| 22 <p class="pending result">Build Pending |
| 21 {{ else }} | 23 {{ else }} |
| 22 <p class="failure result">Unknown status {{.Status.String }} | 24 <p class="failure result">Unknown status {{.Status.String }} |
| 23 {{ end }} | 25 {{ end }} |
| 24 <span class="subtitle"> | 26 <span class="subtitle"> |
| 25 {{ range .Text }}<div class="step-text">{{ . }}</div>{{ end }} | 27 {{ range .Text }}<div class="step-text">{{ . }}</div>{{ end }} |
| 26 </span> | 28 </span> |
| 27 </p> | 29 </p> |
| 28 {{ end }} <!-- with --> | 30 {{ end }} <!-- with --> |
| 29 | 31 |
| 30 | 32 |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 </ul> | 80 </ul> |
| 79 {{ end }} <!-- if --> | 81 {{ end }} <!-- if --> |
| 80 | 82 |
| 81 {{ if .Build.SourceStamp }} | 83 {{ if .Build.SourceStamp }} |
| 82 {{ if .Build.SourceStamp.Source }} | 84 {{ if .Build.SourceStamp.Source }} |
| 83 <h2>Reason:</h2> | 85 <h2>Reason:</h2> |
| 84 <p>{{ .Source }}</p> | 86 <p>{{ .Source }}</p> |
| 85 {{ end }} | 87 {{ end }} |
| 86 {{ end }} | 88 {{ end }} |
| 87 | 89 |
| 88 <h2>Steps and Logfiles:</h2> | 90 {{ if .Build.Components }} |
| 89 <ol> | 91 <h2>Steps and Logfiles:</h2> |
| 90 {{ range .Build.Components }} | 92 <ol> |
| 91 <li> | 93 {{ range .Build.Components }} |
| 92 <div class="status-{{.Status}} result"> | 94 <li> |
| 93 <b>{{.Label}}</b> | 95 <div class="status-{{.Status}} result"> |
| 94 <span style="float:right">( {{ .Duration | humanDuration }} )</span> | 96 <b>{{.Label}}</b> |
| 95 <span> | 97 <span style="float:right">( {{ .Duration | humanDuration }} )</spa
n> |
| 96 {{ range .Text }}<div class="step-text">{{ . }}</div>{{ end }} | 98 <span> |
| 97 </span> | 99 {{ range .Text }}<div class="step-text">{{ . }}</div>{{ end }} |
| 98 </div> | 100 </span> |
| 99 <ul> | 101 </div> |
| 100 {{ if .MainLink }} | 102 <ul> |
| 101 <li>{{.MainLink | linkify}}</li> | 103 {{ if .MainLink }} |
| 102 {{ end }} | 104 <li>{{.MainLink | linkify}}</li> |
| 103 {{ range .SubLink }} | 105 {{ end }} |
| 104 <li>{{. | linkify}}</li> | 106 {{ range .SubLink }} |
| 105 {{ end }} | 107 <li>{{. | linkify}}</li> |
| 106 {{ if not (or .MainLink .SubLink) }} | 108 {{ end }} |
| 107 <li> - no logs - </li> | 109 {{ if not (or .MainLink .SubLink) }} |
| 108 {{ end }} | 110 <li> - no logs - </li> |
| 109 </ul> | 111 {{ end }} |
| 110 </li> | 112 </ul> |
| 111 {{ end }} | 113 </li> |
| 112 </ol> | 114 {{ end }} |
| 115 </ol> |
| 116 {{ end }} <!-- if .Build.Components --> |
| 113 | 117 |
| 114 </div> | 118 </div> |
| 115 | 119 |
| 116 <div class="column"> | 120 <div class="column"> |
| 117 | 121 |
| 118 <h2>Build Properties:</h2> | 122 <h2>Build Properties:</h2> |
| 119 | 123 |
| 120 <table class="info" width="100%"> | 124 <table class="info" width="100%"> |
| 121 <tr><th>Name</th><th>Value</th><th>Source</th></tr> | 125 <tr><th>Name</th><th>Value</th><th>Source</th></tr> |
| 122 | 126 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 148 {{ range .Build.Blame }} | 152 {{ range .Build.Blame }} |
| 149 <li>{{ .AuthorName }} ({{ .AuthorEmail | obfuscateEmail }})</li> | 153 <li>{{ .AuthorName }} ({{ .AuthorEmail | obfuscateEmail }})</li> |
| 150 {{ end }} | 154 {{ end }} |
| 151 </ol> | 155 </ol> |
| 152 {{ end }} | 156 {{ end }} |
| 153 | 157 |
| 154 <h2>Timing:</h2> | 158 <h2>Timing:</h2> |
| 155 <table class="info" width="100%"> | 159 <table class="info" width="100%"> |
| 156 <tr class="alt"><td class="left">Start</td> | 160 <tr class="alt"><td class="left">Start</td> |
| 157 <td> | 161 <td> |
| 158 <span id="started-time">{{ .Build.Summary.Started | humanTimeRFC }}</s
pan> | 162 <span id="started-time"> |
| 163 {{ if .Build.Summary.Started }} |
| 164 {{ .Build.Summary.Started | humanTimeRFC }} |
| 165 {{ else }} |
| 166 N/A |
| 167 {{ end }} |
| 168 </span> |
| 159 </td></tr> | 169 </td></tr> |
| 160 <tr><td class="left">End</td> | 170 <tr><td class="left">End</td> |
| 161 <td> | 171 <td> |
| 162 <span id="finished-time">{{ .Build.Summary.Finished | humanTimeRFC }}<
/span> | 172 <span id="finished-time"> |
| 173 {{ if .Build.Summary.Finished }} |
| 174 {{ .Build.Summary.Finished | humanTimeRFC }} |
| 175 {{ else }} |
| 176 N/A |
| 177 {{ end }} |
| 178 </span> |
| 163 </td></tr> | 179 </td></tr> |
| 164 <tr class="alt"><td class="left">Elapsed</td> | 180 <tr class="alt"><td class="left">Elapsed</td> |
| 165 <td id="duration"> | 181 <td id="duration"> |
| 166 {{ .Build.Summary.Duration | humanDuration }} | 182 {{ if .Build.Summary.Started }} |
| 183 {{ .Build.Summary.Duration | humanDuration }} |
| 184 {{ else }} |
| 185 N/A |
| 186 {{ end }} |
| 167 </td></tr> | 187 </td></tr> |
| 168 </table> | 188 </table> |
| 169 | 189 |
| 170 </div> | 190 </div> |
| 171 | 191 |
| 172 {{ if .Build.Blame}} | 192 {{ if .Build.Blame}} |
| 173 <div class="column"> | 193 <div class="column"> |
| 174 <h2>All Changes:</h2> | 194 <h2>All Changes:</h2> |
| 175 <ol> | 195 <ol> |
| 176 {{ range .Build.Blame }} | 196 {{ range .Build.Blame }} |
| 177 <li> | 197 <li> |
| 178 <h3>{{.Title}}</h3> | 198 <h3>{{.Title}}</h3> |
| 179 <!--- TODO(hinoka): Layout the rest of this --> | 199 <!--- TODO(hinoka): Layout the rest of this --> |
| 180 </li> | 200 </li> |
| 181 {{ end }} | 201 {{ end }} |
| 182 </ol> | 202 </ol> |
| 183 </div> | 203 </div> |
| 184 {{ end }} | 204 {{ end }} |
| 185 | 205 |
| 186 </div> | 206 </div> |
| 187 </div> | 207 </div> |
| 188 {{end}} | 208 {{end}} |
| 189 | 209 |
| 190 {{define "after_body"}} | 210 {{define "after_body"}} |
| 191 <script> | 211 <script> |
| 192 (function() { | 212 (function() { |
| 193 'use strict'; | 213 'use strict'; |
| 194 var startedSpan = document.getElementById('started-time'); | 214 var startedSpan = document.getElementById('started-time'); |
| 195 var finishedSpan = document.getElementById('finished-time'); | 215 var finishedSpan = document.getElementById('finished-time'); |
| 196 startedSpan.textContent = milo.formatDate('{{ .Build.Summary.Started }}'); | 216 var started = milo.formatDate('{{ .Build.Summary.Started }}'); |
| 197 finishedSpan.textContent = milo.formatDate('{{ .Build.Summary.Finished }}'); | 217 var finished = milo.formatDate('{{ .Build.Summary.Finished }}'); |
| 218 if (started) { |
| 219 startedSpan.textContent = started; |
| 220 } |
| 221 if (finished) { |
| 222 finishedSpan.textContent = finished; |
| 223 } |
| 198 })(); | 224 })(); |
| 199 </script> | 225 </script> |
| 200 {{end}} | 226 {{end}} |
| OLD | NEW |