Skip to content

Instantly share code, notes, and snippets.

@davehunt
Created January 22, 2016 16:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save davehunt/2b04f21e618004ed58ea to your computer and use it in GitHub Desktop.
Save davehunt/2b04f21e618004ed58ea to your computer and use it in GitHub Desktop.
Enable AnsiColor for all Jenkins jobs
import hudson.model.*
import hudson.maven.*
import hudson.tasks.*
for(item in Hudson.instance.items) {
println("job $item.name")
item.getBuildWrappersList().add(new hudson.plugins.ansicolor.AnsiColorBuildWrapper("XTerm", 1, 2) )
item.save()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment