Hi ,

I want to set the PATH variable during setup() of BuildWrapper. and use the 
tools for which i am setting path directly on command line during my build 
step (Builder class). I am trying to set the env variable using below in 
setup() method of Build Wrapper


*initialEnvironment.put("mytoolRoot", getMytoolRoot + nodeSpecificFileSep + 
"bin");*
*initialEnvironment.override("PATH+mytoolRoot",initialEnvironment.get("mytoolRoot")
 
); *

and then just to test i am calling my tool through command line directly 
using Launcher in same setup() method like below 

*launcher.launch().cmdAsSingleString("mytool -batch 
-ver").env(initialEnvironment).stdout(listener).join();*

above command fails to pick up the tool directly through the command line. 
and the build fails with error *Cannot run program "mytool" no such file or 
directory. *

what can i do to set the env variable . the other option i am trying is to 
write batch and shell script file and execute it. but i am not sure if i 
should do that. 

Thanks & Regards
Nikhil 

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-dev/3f181bc3-61aa-4469-9850-d5344b60af9a%40googlegroups.com.

Reply via email to