Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-19 Thread Baptiste Mathus
+1 having both tried the javadoc and ide path in the past, I recommend by far the ide. Discovering code and possibilities through javadoc solely proves terribly cumbersome. Cheers Le 17 mars 2014 00:11, "Richard Lavoie" a écrit : > The IDE is the best way because of the inter class easy navigatio

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-17 Thread Daniel Beck
On 17.03.2014, at 00:50, Richard Lavoie wrote: > But do we have for LTS or previous versions ? Everything introduced later is (or should be) annotated with @since, see e.g. http://javadoc.jenkins-ci.org/hudson/model/AbstractItem.html#getRelativeDisplayNameFrom%28hudson.model.ItemGroup%29 http:

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Richard Lavoie
Sweet, But do we have for LTS or previous versions ? Richard Lavoie > On 2014-03-16, at 19:22, Richard Bywater wrote: > > Its available online @ http://javadoc.jenkins-ci.org/ > > Richard. > > >> On Mon, Mar 17, 2014 at 12:11 PM, Richard Lavoie >> wrote: >> The IDE is the best way because

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Richard Bywater
Its available online @ http://javadoc.jenkins-ci.org/ Richard. On Mon, Mar 17, 2014 at 12:11 PM, Richard Lavoie wrote: > The IDE is the best way because of the inter class easy navigation and the > fact that source code is often submitted along with binaries in macen. > > You could also just lo

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Richard Lavoie
The IDE is the best way because of the inter class easy navigation and the fact that source code is often submitted along with binaries in macen. You could also just look at the javadocs but I don't think it's published online. It is available through maven though. Going from the source with ID

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Christian Goetze
What is the best way to discover all these nice things one could do...? Do I really need to fire up an IDE and explore the source? On Sun, Mar 16, 2014 at 1:41 PM, Christian Goetze < christian.goe...@appdynamics.com> wrote: > Thank you - that appears to work. > > > On Sun, Mar 16, 2014 at 1:37 P

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Christian Goetze
Thank you - that appears to work. On Sun, Mar 16, 2014 at 1:37 PM, Richard Lavoie wrote: > Have you tried hudson.model.Hudson.instance.save() ? > > > On Sun, Mar 16, 2014 at 4:07 PM, Christian Goetze < > christian.goe...@appdynamics.com> wrote: > >> I recently learned that I can use the script c

Re: How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Richard Lavoie
Have you tried hudson.model.Hudson.instance.save() ? On Sun, Mar 16, 2014 at 4:07 PM, Christian Goetze < christian.goe...@appdynamics.com> wrote: > I recently learned that I can use the script console to run groovy scripts > to modify items in the model. > > Specifically, I would like to add, ch

How do I persist changes to the model made via a Groovy script to disk?

2014-03-16 Thread Christian Goetze
I recently learned that I can use the script console to run groovy scripts to modify items in the model. Specifically, I would like to add, change and remove slave node labels via a script. I can make a script like this for example: hudson.model.Hudson.instance.slaves.each { slave -> out.pr