Hot to set a particular buildwrapper using java/Groovy

92 views
Skip to first unread message

Manoj Thakkar

unread,
Dec 18, 2014, 5:15:48 PM12/18/14
to jenkin...@googlegroups.com
Hi, 

I want to enable a build wrapper for each and every job in my project , how do i enable it using groovy  or java,

I wrote this code to get the buildwrapper list , bit could not find a method to set it ,

for(item in Hudson.instance.getItems()) {
     println item.getName()
      println(item.displayName)
     item.buildWrappers.each{
        println("I am using buildwrapper " )
          println  item.buildWrappers 
       }            
    }

The ouptut for code above  is something like this 

I am using buildwrapper 
[org.jenkinsci.plugin.Diskcheck$DescriptorImpl@409bb402:org.jenkinsci.plugin.Diskcheck@238635e4]

ogondza

unread,
Dec 19, 2014, 3:26:43 AM12/19/14
to jenkin...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages