]> git.pld-linux.org Git - projects/distfiles.git/blobdiff - request-handler.pl
- added flags support
[projects/distfiles.git] / request-handler.pl
index 3b186fa07f8bdc1387afc756981772610c865e8d..f792337c8f08ed288697e5100723d6e5ba7825d5 100644 (file)
@@ -7,15 +7,18 @@ $email_cc = "";
 $spec = undef;
 $branch = "";
 $from = undef;
+$flags = "";
 
 $id = `uuidgen`;
 chomp $id;
 $id = rand if (!defined $id or $id eq "");
 
 while (<STDIN>) {
+  chomp;
   /^X-Spec: ([\+a-zA-Z0-9_\-]+\.spec)/i and $spec = $1;
   /^X-Branch: ([a-zA-Z0-9_\-]+)/i and $branch = $1;
   /^X-Login: ([a-zA-Z0-9_]+)/i and $from = $1;
+  /^X-Flags: ([a-zA-Z0-9\-_ ]+)/i and $flags = $1;
 }
 
 die "ill-formed request" if (!defined $from);
@@ -37,6 +40,7 @@ chdir("../..");
 
 open(S, "> tmp/$id/to-spool");
 print S "$from\@pld-linux.org\n";
+print S "$flags\n";
 close(S);
 
 if (system("./specparser.pl \"tmp/$id/SPECS/$spec\" >> tmp/$id/to-spool") != 0) {
This page took 0.128556 seconds and 4 git commands to generate.