This is my experiment, I am actually trying to do this is a post-build Groovy 
step.

What I am “actually” trying to do is change or create a build variable in 
either a Build Flow step or a post-build groovy step so that it is available to 
a subsequent post build step. I am doing this now by writing a properties file 
to the workspace during the buildflow step and injecting that file during the 
post build steps. But this seems clunky.

From: [email protected] 
[mailto:[email protected]] On Behalf Of Marc MacIntyre
Sent: Wednesday, October 22, 2014 1:43 PM
To: [email protected]
Subject: Re: groovy script problem

I think the variables set on a completed build are probably read-only.  If 
you're looking to pull the last build's variables, modify, then re-use them, 
you probably want something like:
def newvars = build.buildVariables.clone()
etc...

On Wed, Oct 22, 2014 at 10:36 AM, Ginga, Dick 
<[email protected]<mailto:[email protected]>> wrote:
I am admittedly a novice at Groovy but this script does not complain about the 
“put” operation but does not apparently perform it:
label-name is a parameter in that build.

[cid:[email protected]]

Dick Ginga, Informatics R&D
PerkinElmer Inc. | For the Better
HUMAN HEALTH | ENVIRONMENTAL HEALTH
940 Winter Street, Waltham MA 02451

[email protected]<mailto:[email protected]>
Mobile – 508-847-1434<tel:508-847-1434>
Office – 781-663-6947<tel:781-663-6947>

--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
For more options, visit https://groups.google.com/d/optout.



--
Marc MacIntyre
--
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to 
[email protected]<mailto:[email protected]>.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to