Thanks, simply using double quotes instead of single works fine.

bat "echo MYKEY is %MYKEY%"



On Thu, 26 Jan 2017 at 14:25 Daniel Beck <m...@beckweb.net> wrote:

>
> > On 26.01.2017, at 12:57, Mark Allison <markalli...@gmail.com> wrote:
> >
> > How can I load variables from a file in a Windows job and have them
> loaded into the environment at run time?
>
> These are just Groovy variables. You didn't specify for them to be passed
> to launched processes' environment (as e.g. build parameters automatically
> are).
>
> withEnv(…) should work.
>
> env.VAR = 'value' probably too, but am not sure whether that's a
> recommended approach.
>
> --
> 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 jenkinsci-users+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/32EBB24D-996C-4CE4-8C1B-B1E8ECD6560F%40beckweb.net
> .
> For more options, visit https://groups.google.com/d/optout.
>
-- 

Sent from my phone

-- 
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 jenkinsci-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAN9sP2ZjGkjBkC3nDfHTgYX%3D11H%3DjsVDNtaPMkjgzc%3D_bE6DrQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to