hydra: in case of cached build, add link to build that built the storepath

This commit is contained in:
Rob Vermaas
2010-01-15 14:18:12 +00:00
parent 3bed0863a5
commit 63db13be3f
2 changed files with 13 additions and 0 deletions

View File

@ -38,6 +38,12 @@ sub view_build : Chained('build') PathPart('') Args(0) {
my $logfile = $build->schedulingInfo->logfile;
$c->stash->{logtext} = `cat $logfile` if -e $logfile;
}
if (defined $build->resultInfo && $build->resultInfo->iscachedbuild) {
(my $cachedBuildStep) = $c->model('DB::BuildSteps')->search({ outpath => $build->outpath }, {}) ;
$c->stash->{cachedBuild} = $cachedBuildStep->build;
}
}