This gem allows you to interact with Hudson’s remote access api using Ruby. So far the features include triggering builds, disabling jobs, copying jobs, updating job configuration and more.
I have used this set of scripts to automated many tasks with Hudson. Here are some examples of what you can do.
Get a list of all Hudson jobs currently building:
List all Hudson jobs in the build queue:
Get the next build number for a Hudson job:
job = Hudson::Job.new('jobname') job.next_build_number
Trigger a build:
job = Hudson::Job.new('jobname') job.build
Create a new Hudson job to build from an SVN branch:
job1 = Hudson::Job.new('jobname') job2 = job1.copy job2.repository_url = job2.repository_url.sub("trunk", "branches")