Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

16 lines (12 sloc) 0.338 kB
import jenkins
import re
import xml.dom.minidom
REGEX = '@auto-demand'
j = jenkins.Jenkins('http://localhost:8080')
jobs = j.get_jobs();
for job in jobs:
job_name = job['name']
job_desc = j.get_job_info(job_name)['description']
if re.match(REGEX, job_desc):
print 'Deleting %s' % (job_name)
j.delete_job(job_name)
Jump to Line
Something went wrong with that request. Please try again.