git ref in status display
[buildfarm-server.git] / templates / history.tt
1 [%#
2
3 Copyright (c) 2003-2010, Andrew Dunstan
4 Copyright (c) 2022, The Exim Maintainers
5
6 See accompanying License file for license details
7
8 -%]
9 [%- BLOCK cl %] class="[% SWITCH bgfor -%]
10   [%- CASE 'OK' %]pass[% CASE 'ContribCheck' %]warn[% CASE [ 'Check' 'InstallCheck' ] %]warnx[% CASE %]fail[% END %]"
11 [%- END -%]
12 [% WRAPPER 'page.tt' 
13         title = 'Exim BuildFarm History'
14         bodyclass = 'history'
15         pagebutton = 'none'
16 %]
17 <h1>Exim BuildFarm Status History</h1>
18   <table cellspacing="0">
19     <tr><th class="head" colspan="3">System Detail</th></tr>
20     <tr class="member"><th>Farm member</th><td>[% member %]</td></tr>
21     <tr><th>OS</th><td>[% statrows.0.operating_system %] [% statrows.0.os_version %]</td></tr>
22     <tr><th>Compiler</th><td>[% statrows.0.compiler %] [% statrows.0.compiler_version %]</td></tr>
23     <tr><th>Architecture</th><td>[% statrows.0.architecture %]</td></tr>
24     <tr><th>Owner</th><td>[% statrows.0.owner_email %]</td></tr>
25   </table>
26 [% IF statrows.0.sys_notes %]
27     <br />
28     <table>
29      <tr>
30        <th class="head" rowspan="2">System Notes</th>
31        <th>Date</th>
32        <th>Notes</th>
33      </tr>
34      <tr>
35       <td>[% statrows.0.sys_notes_date %]</td>
36       <td>[% statrows.0.sys_notes %]</td>
37      </tr>
38    </table>
39 [% END %]
40   <h3>Branch: [% branch %][% IF statrows.size >= hm %] (last [% hm %] entries shown)[% END %]</h3>
41 [%
42  res_imgs = {
43      P = '/img/t_good.gif',
44      F => '/img/t_fail.gif',
45      '.' => '/img/t_notdone.gif',
46      }
47 -%]
48 [%# The IF-backstop is ugly and I'm not understanding why the res_img lookup does not for for '.' -%]
49 [%- BLOCK colour ; IF res_imgs.$c.defined ; res_imgs.$c ; ELSE %]/img/t_notdone.gif [% END; END %]
50 [%- BLOCK colourbar %]<img src=[% PROCESS colour %] title="[% st %]-[% st + w - 1 %]" height=16 width=[% w %] class=inline align=bottom/>[%- END -%]
51 [% BLOCK stdet %]
52     <tr [% PROCESS cl bgfor=row.stage %]>
53       <td>[%- row.when_ago | replace('\s','&nbsp;') %]&nbsp;ago&nbsp;</td>
54       <td class="status">[% row.stage -%] [[% row.git_head_ref.substr(0,7) %]]</td>
55
56       <td class="status"><a href="show_log.pl?nm=
57                [%- row.sysname %]&amp;dt=
58                [%- row.snapshot | uri %]">
59                 [%- IF row.stage != 'OK' %]Details[% ELSE %]Config[% END -%]</a></td>
60       <td class="tests">[% FOREACH range IN row.log_text ;
61         r = range.split(' '); c = r.0; st = r.1; w = r.2; PROCESS colourbar; END %]</td>
62     </tr>
63 [% END %]
64     <td><table cellspacing="0">
65         [% FOREACH xrow IN statrows %][% PROCESS stdet row=xrow %][% END %]
66     </table></td>
67 [% END %]