My jenkins
projects has a parameterized build. I am trying to pass a String parameter to a bat script as ***.ps1 -param1=$param1
.
Asked
Active
Viewed 1,080 times
0

thor
- 21,418
- 31
- 87
- 173

sasi kumar
- 1
- 1
1 Answers
0
You should be able to access environment variables (including job paramters) in your script by using %param1%
. Environment variable should already be accessible withing your bat script environment (e.g. you don't have to pass them to the bat script if you are running it as a build step). However, if you are trying to pass a parameter on the command line, you should be able to access the parameter like this: ${param1}
.

TheEllis
- 1,666
- 11
- 18