Permalink
Browse files

Merge /home/eduardo/gitbuilder

* /home/eduardo/gitbuilder:
  Add support for forcing rebuild
  • Loading branch information...
2 parents 3417a4d + 251fac5 commit ae4c4c98452d84a937254862b34259381dc2d06b @apenwarr committed Dec 12, 2008
Showing with 31 additions and 8 deletions.
  1. +13 −8 out/index.cgi
  2. +17 −0 out/rebuild.cgi
  3. +1 −0 run-build.sh
View
@@ -208,14 +208,15 @@ for my $bpb (sort { lc($a) cmp lc($b) } @branchlist) {
my $failed;
my $logcgi = "log.cgi?log=$commit";
+ my $rebuildcgi = "rebuild.cgi?log=$commit";
$email =~ s/\@.*//;
my $commitlink = commitlink($commit, shorten($commit, 7, ""));
$comment =~ s/^\s*-?\s*//;
- sub pushrow(\@$$$$$$)
+ sub pushrow(\@$$$$$$$)
{
my ($_branchout, $status, $commitlink,
- $email, $codestr, $comment, $logcgi) = @_;
+ $email, $codestr, $comment, $logcgi, $rebuildcgi) = @_;
my $statcode = status_to_statcode($status);
@@ -229,9 +230,13 @@ for my $bpb (sort { lc($a) cmp lc($b) } @branchlist) {
td({class=>"committer"}, $email),
td({class=>"details"},
a({class=>"hyper", name=>$branch}, "") . div(
- span({class=>"codestr"},
- $logcgi ? a({-href=>$logcgi}, $codestr) : $codestr),
- span({class=>"comment"}, $comment)))
+ span({class=>"codestr"},
+ $logcgi ? a({-href=>$logcgi}, $codestr) : $codestr),
+ span({class=>"comment"}, $comment),
+ span({class=>"hyper"},
+ ("$statcode" eq "err") ? "(" .
+ a({-href=>$rebuildcgi}, "Force Rebuild") . ")" : "")
+ ))
);
$branchprint = "";
}
@@ -245,12 +250,12 @@ for my $bpb (sort { lc($a) cmp lc($b) } @branchlist) {
} elsif ($commit eq $currently_doing) {
# currently building this one
pushrow(@branchout, "BUILDING",
- $commitlink, $email, "", $comment, "");
+ $commitlink, $email, "", $comment, "", "");
next;
} elsif ($last_was_pending == 0 && $print_pending) {
# first pending in a group: print (Pending)
pushrow(@branchout, "(Pending)",
- $commitlink, $email, "", $comment, "");
+ $commitlink, $email, "", $comment, "", "");
$last_was_pending = 1;
next;
} else {
@@ -263,7 +268,7 @@ for my $bpb (sort { lc($a) cmp lc($b) } @branchlist) {
my $status = ($warnmsg eq "ok") ? "ok"
: ($warnmsg =~ /^Warnings\(\d+\)$/) ? "Warn" : "FAIL";
pushrow(@branchout, $status,
- $commitlink, $email, $warnmsg, $comment, $logcgi);
+ $commitlink, $email, $warnmsg, $comment, $logcgi, $rebuildcgi);
}
do_pending_dots(@branchout);
View
@@ -0,0 +1,17 @@
+#!/usr/bin/perl -w
+use strict;
+use CGI::Pretty qw/:standard/;
+use lib ".";
+use Autobuilder;
+
+my $commit = param('log');
+$commit =~ s/[^0-9A-Za-z]/_/g;
+$commit =~ s/^\./_/;
+
+my $fn;
+$fn = "fail/$commit";
+if (-f $fn) {
+ unlink($fn);
+}
+
+print redirect(-location=>".");
View
@@ -9,6 +9,7 @@ fi
ref="$1"
mkdir -p out/fail out/pass
+chmod 777 out/fail
log()
{

0 comments on commit ae4c4c9

Please sign in to comment.