]> iEval git - gruntmaster-daemon.git/commitdiff
Add contest support to gensrc
authorMarius Gavrilescu <marius@ieval.ro>
Thu, 30 Jan 2014 16:27:55 +0000 (18:27 +0200)
committerMarius Gavrilescu <marius@ieval.ro>
Thu, 30 Jan 2014 16:27:55 +0000 (18:27 +0200)
lib/Gruntmaster/Daemon.pm

index d6369656337bdf37152c0b1d950317fdce3496fc..c3ee5914c5cd5244bfe28ac5d38aefbd7bf0c596 100644 (file)
@@ -130,7 +130,7 @@ sub process{
   set_job_errors $job, $errors;
 
   my $log = $Gruntmaster::Data::contest ? "ct/$Gruntmaster::Data::contest/log" : 'log';
-  PUBLISH gensrc => $job;
+  PUBLISH gensrc => "$Gruntmaster::Data::contest.$job";
   PUBLISH genpage => "$log/job/$job.html";
   PUBLISH genpage => "$log/index.html";
   PUBLISH genpage => "$log/st.html";
@@ -143,7 +143,7 @@ sub process{
 sub got_job{
        $_[0] =~ /^(\w*)\.(\d+)$/;
        my $job = $2;
-       $Gruntmaster::Data::contest = $1 if $1;
+       local $Gruntmaster::Data::contest = $1 if $1;
        get_logger->debug("Taking job $job@{[defined $1 ? \" of contest $1\" : '']}...");
        if (set_job_daemon $job, hostname . ":$$") {
                get_logger->debug("Succesfully taken job $job");
This page took 0.030764 seconds and 4 git commands to generate.