It is hard to answer this without more detail on your jobs. i.e. Is this a freestyle job? How and where is the environment variable set? Sounds to me like a scope issue. For example, if you are setting the variable in one shell script, then trying to get to it in another, it isn't going to work.
On Friday, October 6, 2017 at 10:38:12 AM UTC-6, gurudatt SA wrote:
The code which is executing in the workstation is setting an System variable. And i want to read the system variable from jenkins job - Windows batch command during execution.
Is there a way to do this ?
I have tried the classic way to read the system variable from command line - Echo %MyVariable%, but its not returning anything.