I am writing a job in Jenkins using DSL script (& Groovy) that will generate a job further. In the generated job I want the artefacts after compilation to be stored at D:\Jen\<CURRENT_MONTH_YEAR>
e.g. D:\Jen\06_2016
.
So, I declare an environment variable in Jenkins with value D:\Jen
under Properties Content (not by adding a build step Inject Environment Variable but the Properties Content option before SCM configuration).
Now, in a batch file (using batchFile API in the script) I derive the month and year: 06_2016
.
So, my question is how do I share this value I got in batch file with my environment variable.