* hdyra: show last succeeded build and changes since on build status summary if build has failed

This commit is contained in:
Rob Vermaas 2010-02-23 13:08:58 +00:00
parent 529a6cf6eb
commit 3ff2934400
2 changed files with 16 additions and 10 deletions

View file

@ -176,14 +176,23 @@
[% END %]
[% IF !build.finished %]
[% INCLUDE renderBuildSteps type="Running" %]
[% INCLUDE renderBuildSteps type="Running" %]
[% END %]
[% IF build.finished %]
[% IF build.buildsteps && (build.resultInfo.buildstatus == 2 || build.resultInfo.buildstatus == 5)%]
[% IF build.buildsteps && build.resultInfo.buildstatus != 0 %]
[% INCLUDE renderBuildSteps type="Failed" %]
[% END %]
[% IF build.resultInfo.buildstatus != 0 && prevSuccessfulBuild %]
<h2>Changes</h2>
<p>
The previous successful build of this job was [% INCLUDE renderFullBuildLink build=prevSuccessfulBuild %]. The
following changes were made since:
</p>
[% INCLUDE renderInputDiff build2=build , build1=prevSuccessfulBuild %]
[% END %]
[% IF build.resultInfo.errormsg && build.resultInfo.buildstatus != 5 %]
<h2 id="nix-error">Nix error output</h2>
@ -384,14 +393,11 @@
</tbody>
</table>
[% IF prevBuild %]
<h2>Changes since previous build : [% INCLUDE renderFullBuildLink build=prevBuild %]</h2>
[% INCLUDE renderInputDiff build2=build , build1=prevBuild %]
[% END %]
<p/>
[% IF prevBuild && prevSuccessfulBuild.id != prevBuild.id %]
<h2>Changes since previous successful build : [% INCLUDE renderFullBuildLink build=prevSuccessfulBuild %]</h2>
[% INCLUDE renderInputDiff build2=build , build1=prevSuccessfulBuild %]
[% IF prevBuild %]
<h3>Changes since previous build : [% INCLUDE renderFullBuildLink build=prevBuild %]</h3>
[% INCLUDE renderInputDiff build2=build , build1=prevBuild %]
[% END %]
</div>

View file

@ -198,7 +198,7 @@
[% END -%]
[% BLOCK renderFullBuildLink; %]
Job [% INCLUDE renderFullJobNameOfBuild build=build %] <a href="[% c.uri_for('/build' build.id) %]">build [% build.id %]
[% INCLUDE renderFullJobNameOfBuild build=build %] <a href="[% c.uri_for('/build' build.id) %]">build [% build.id %]</a>
[% END %]
[% BLOCK renderBuildStatusIcon; %]