Merge pull request #299 from corpsee/master

A few minor fixes
This commit is contained in:
Dan Cryer 2014-03-12 17:08:36 +00:00
commit cf43a20c86
2 changed files with 18 additions and 2 deletions

View file

@ -65,7 +65,11 @@ class RemoteGitBuild extends Build
protected function cloneByHttp(Builder $builder, $cloneTo)
{
$success = $builder->executeCommand('git clone -b %s %s "%s"', $this->getBranch(), $this->getCloneUrl(), $cloneTo);
$builder->executeCommand('cd "%s" && git checkout %s', $cloneTo, $this->getCommitId());
if (!empty($commit) && $commit != 'Manual') {
$builder->executeCommand('cd "%s" && git checkout %s', $cloneTo, $this->getCommitId());
}
return $success;
}

View file

@ -46,7 +46,19 @@ switch($build->getStatus())
print ' - ';
}
?></a></td>
<td><a href="<?php print $build->getCommitLink(); ?>"><?php print $build->getCommitId(); ?></a></td>
<td>
<?php
if ($build->getCommitId() !== 'Manual') {
print '<a href="' . $build->getCommitLink() . '">';
}
print $build->getCommitId();
if ($build->getCommitId() !== 'Manual') {
print '</a>';
}
?>
</td>
<td><a href="<?php print $build->getBranchLink(); ?>"><?php print $build->getBranch(); ?></a></td>
<td>
<?php