jenkins - How to set a Views description in Groovy -


i'm dynamically creating view via groovy with..

jenkins.instance.getitem('my_folder').addview(new listview('mynewview') 

this works great; , add filter view via..

jenkins.instance.getitem('my_folder').getview('mynewview').setincluderegex('.*newview.*' 

which works wonderfully. how programmatically set views description? assume there's combination can

dosubmitdescription(...?) 

but haven't been able sus out.. appreciated.

my current plan work around posting getview('mynewview').geturl()+"/submitdescription...";

but should cleaner that..

if want update view's description, here line looking for:

import org.kohsuke.stapler.staplerrequest import org.kohsuke.stapler.staplerresponse  jenkins.instance.getview('mynewview').dosubmitdescription([ getparameter: { return "my description"; }] staplerrequest, [ sendredirect: { return; } ] staplerresponse) 

Comments

Popular posts from this blog

mysql - Dreamhost PyCharm Django Python 3 Launching a Site -

java - Sending SMS with SMSLib and Web Services -

java - How to resolve The method toString() in the type Object is not applicable for the arguments (InputStream) -