lib/coderunner/instance_methods.rb in coderunner-0.14.21 vs lib/coderunner/instance_methods.rb in coderunner-0.14.22

- old
+ new

@@ -1,8 +1,6 @@ -# A comment - class CodeRunner # declare the constant end # = CodeRunner Overview @@ -1164,10 +1162,11 @@ #@executable ||= runs[0].executable @submission_script = script # A hook... default is to do nothing @submission_script = @run_class.modify_job_script(self, runs, @submission_script) # To get out of job_chain_files folder + p 'test' @submission_script = "cd .. \n" + @submission_script old_job_nos = queue_status.scan(/^\s*(\d+)/).map{|match| match[0].to_i} ################ Submit the run Dir.chdir('job_chain_files'){job_no = execute} ################ @@ -1725,27 +1724,27 @@ relative = run.directory.delete_substrings(@root_folder, File.basename(run.directory)) FileUtils.makedirs(temp_root + relative) unless FileTest.exist? temp_root + relative + archive_name eputs "Archiving #{index} out of #{size}" if options[:verbose] Dir.chdir(run.directory + '/..') do - command = "tar -cW#{very_verbose}f #{tar_name} #{File.basename(run.directory)}" - eputs command if options[:verbose] - unless system command - raise "Archiving failed" - end - break unless comp - command = "gzip -4 -vf #{tar_name}" - eputs command if options[:verbose] - unless system command - raise "Compression failed" - end - command = "gzip -t #{archive_name}" - eputs command if options[:verbose] - unless system command - raise "Compression failed" - end - #exit + command = "tar -cW#{very_verbose}f #{tar_name} #{File.basename(run.directory)}" + eputs command if options[:verbose] + unless system command + raise "Archiving failed" + end + break unless comp + command = "gzip -4 -vf #{tar_name}" + eputs command if options[:verbose] + unless system command + raise "Compression failed" + end + command = "gzip -t #{archive_name}" + eputs command if options[:verbose] + unless system command + raise "Compression failed" + end + #exit end FileUtils.mv(relative.delsubstr('/') + archive_name, temp_root + '/' + relative + archive_name) end system "chgrp -R #{options[:group]} #{temp_root}" if options[:group] @@ -1768,25 +1767,13 @@ end FileUtils.mv(".tmparch/#{File.basename(@root_folder)}.tar", "#{File.basename(@root_folder)}.tar") #FileUtils.rm_r(".tmparch") end end - - - - - end - - - - - - - [ - "/graphs_and_films.rb", + "/graphs_and_films.rb", "/remote_code_runner.rb", "/merged_code_runner.rb", '/run.rb', '/heuristic_run_methods.rb', ].each do |file|