Skip to content

Instantly share code, notes, and snippets.

View jpgxs's full-sized avatar
🌍

Joshua Griffiths jpgxs

🌍
  • Origin Digital
  • UK
View GitHub Profile
@nextrevision
nextrevision / deleteJenkinsJobs.groovy
Created December 3, 2015 17:30
Groovy script to delete all jenkins jobs that match a regex pattern
import jenkins.model.*
def matchedJobs = Jenkins.instance.items.findAll { job ->
job.name =~ /my_regex_here/
}
matchedJobs.each { job ->
println job.name
//job.delete()
}