Turn repeated dependencies into hyperlinks

This commit is contained in:
Eelco Dolstra 2013-02-20 01:28:29 +01:00
parent 18da3ac397
commit 1feca4b105
2 changed files with 21 additions and 13 deletions

View file

@ -2,27 +2,30 @@
[% PROCESS common.tt %] [% PROCESS common.tt %]
[% USE HTML %] [% USE HTML %]
[% project = build.project %] [% project = build.project;
[% jobset = build.jobset %] jobset = build.jobset;
[% job = build.job %] job = build.job;
global.nodeId = 1 %]
[% BLOCK renderNode %] [% BLOCK renderNode %]
<li> <li>
[% IF done.${node.path} %] [% IF done.${node.path} %]
<tt>[% node.name %]</tt> (<em>repeated</em>) <a href="#[% done.${node.path} %]"><tt>[% node.name %]</tt></a>
[% ELSE %] [% ELSE %]
[% done.${node.path} = 1 %] [% done.${node.path} = global.nodeId; global.nodeId = global.nodeId + 1; %]
[% IF node.refs.size > 0 %] [% IF node.refs.size > 0 %]
<a href="javascript:" class="tree-toggle"></a> <a href="javascript:" class="tree-toggle"></a>
[% END %] [% END %]
[% IF node.buildStep %] <span class="dep-tree-line" id="[% done.${node.path} %]">
<a href="[% c.uri_for('/build' node.buildStep.get_column('build')) %]"><tt>[% node.name %]</tt></a> [% [% IF node.buildStep %]
IF log_exists(node.buildStep.drvpath); <a href="[% c.uri_for('/build' node.buildStep.get_column('build')) %]"><tt>[% node.name %]</tt></a> [%
INCLUDE renderLogLinks url=c.uri_for('/build' node.buildStep.get_column('build') 'nixlog' node.buildStep.stepnr); IF log_exists(node.buildStep.drvpath);
END %] INCLUDE renderLogLinks url=c.uri_for('/build' node.buildStep.get_column('build') 'nixlog' node.buildStep.stepnr);
[% ELSE %] END %]
<tt>[% node.name %]</tt> [% ELSE %]
[% END %] <tt>[% node.name %]</tt> (<em>no info</em>)
[% END %]
</span>
[% IF node.refs.size > 0 %] [% IF node.refs.size > 0 %]
<ul class="subtree"> <ul class="subtree">
[% FOREACH ref IN node.refs; INCLUDE renderNode node=ref; END %] [% FOREACH ref IN node.refs; INCLUDE renderNode node=ref; END %]

View file

@ -24,3 +24,8 @@ table.productList {
border-collapse: separate; border-collapse: separate;
border-spacing: 0em 1em; border-spacing: 0em 1em;
} }
span.dep-tree-line:target {
background-color: #f8f8e0;
font-style: italic;
}