Ubuntu Pastebin

Paste from a at Tue, 3 Feb 2015 14:30:53 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
require_relative 'lib/jenkins'

$jenkins = new_jenkins()
$job = $jenkins.job

jobs = $job.list(/^utopic_stable_.*/)
jobs.each do |name|
    puts "-- checking :: #{name} --"

#     unless $job.status(name) == 'success' or $jenkins.queue.list.include?(name)
        next if $job.status(name) == 'running'
        puts " -> building"
        $job.build(name)
#     end
end
Download as text