? .htaccess
? index.html
? perlside.patch
? redsearch.patch
? roughpatch.patch
Index: sendchange-ui.pm
===================================================================
RCS file: /cvsroot/mozilla/webtools/buildbot-try/sendchange-ui.pm,v
retrieving revision 1.4
diff -u -8 -p -r1.4 sendchange-ui.pm
--- sendchange-ui.pm 2 Jan 2008 21:13:46 -0000 1.4
+++ sendchange-ui.pm 9 May 2008 21:01:31 -0000
@@ -69,26 +69,30 @@ __END_OF_HTML__
}
sub WritePage
{
my %args = @_;
my $patchLevel = "0";
+ my $project = "browser";
my $branch = "";
my $identifier = "";
my $description = "";
my $type = "patch";
my $mozillaRepoPath = $MOZILLA_REPO_PATH;
my $tamarinRepoPath = $TAMARIN_REPO_PATH;
my @err;
if (exists $args{'patchLevel'} && $args{'patchLevel'} !~ /^\s*$/) {
$patchLevel = $args{'patchLevel'};
}
+ if (exists $args{'project'} && $args{'project'} !~ /^\s*$/) {
+ $project = $args{'project'};
+ }
if (exists $args{'branch'} && $args{'branch'} !~ /^\s*$/) {
$branch = $args{'branch'};
}
if (exists $args{'identifier'} && $args{'identifier'} !~ /^\s*$/) {
$identifier = $args{'identifier'};
}
if (exists $args{'description'} && $args{'description'} !~ /^\s*$/) {
$description = $args{'description'};
@@ -327,16 +331,29 @@ __END_OF_HTML__
(required)
+ |
+
+ |
+
+
?:
|
|
Index: sendchange.cgi
===================================================================
RCS file: /cvsroot/mozilla/webtools/buildbot-try/sendchange.cgi,v
retrieving revision 1.2
diff -u -8 -p -r1.2 sendchange.cgi
--- sendchange.cgi 16 Oct 2007 15:16:03 -0000 1.2
+++ sendchange.cgi 9 May 2008 21:01:31 -0000
@@ -57,16 +57,17 @@ sub Process
# used for ensuring non-conflicting filenames
my $time = time();
my $key = int(rand(1000));
# get the parameters
my $name = $ENV{'REMOTE_USER'};
my $type = param('type');
my $patchFile = param('patchFile');
my $patchLevel = param('patchLevel');
+ my $project = param('project');
my $branch = param('branch');
my $mozillaRepoPath = param('mozilla-repo');
my $tamarinRepoPath = param('tamarin-repo');
my $identifier = param('identifier');
my $description = param('description');
my $mozconfig = param('mozconfig');
my (@err, $infoFile);
@@ -134,16 +135,17 @@ sub Process
# write the patch
my $filename = catfile($PATCH_DIR, $patchFile);
if (! open(PATCH, ">$filename")) {
push(@err, 'Server error - Could not open file for writing');
}
if (scalar(@err) > 0) {
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
@@ -163,31 +165,33 @@ sub Process
}
if (!get($tamarinRepoPath)) {
push(@err, 'Tamarin repository path is not valid');
}
if (scalar(@err) > 0) {
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
}
# generate the infofile name
$infoFile = "$time-$key-hg.info";
} else {
push(@err, 'Please test a patch or a Mercurial repository.');
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
@@ -196,31 +200,33 @@ sub Process
my $mozconfigHandle = upload('mozconfig');
if (! -z $mozconfigHandle) {
$mozconfig = "$time-$key-$mozconfig";
my $filename = catfile($PATCH_DIR, $mozconfig);
if (! open(MOZCONFIG, ">$filename")) {
push(@err, 'Server error - Could not open file for writing');
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
}
while (<$mozconfigHandle>) {
print MOZCONFIG;
}
if (! close(MOZCONFIG)) {
push(@err, "Server error - Could not close mozconfig file");
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
@@ -228,54 +234,58 @@ sub Process
}
# now write the infofile
my $filename = catfile($PATCH_DIR, $infoFile);
if (! open(INFO, ">$filename")) {
push(@err, 'Server error - Could not open file for writing');
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
}
print INFO "submitter: $name\n";
print INFO "type: $type\n";
if ($type eq "patch") {
print INFO "patchFile: $patchFile\n";
print INFO "patchLevel: $patchLevel\n";
+ print INFO "project: $project\n";
print INFO "branch: $branch\n";
} elsif ($type eq "hg") {
print INFO "mozillaRepoPath: $mozillaRepoPath\n";
print INFO "tamarinRepoPath: $tamarinRepoPath\n";
} else {
push(@err, 'Please test a patch or a Mercurial repository.');
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;
}
print INFO "identifier: $identifier\n";
print INFO "mozconfig: $mozconfig\n";
print INFO "description: $description\n";
if (! close(INFO)) {
push(@err, "Could not close info file.");
WritePage(patchLevel => $patchLevel,
+ project => $project,
branch => $branch,
identifier => $identifier,
description => $description,
type => $type,
mozillaRepoPath => $mozillaRepoPath,
tamarinRepoPath => $tamarinRepoPath,
err => \@err);
return;