How I pass params from Jenkins to build.gradle?

前端 未结 3 1092
攒了一身酷
攒了一身酷 2020-12-22 00:44

I want to pass value to my build.gradle file through jenkins (build with params).

I have a String and I need to use this String params to make my release ?

3条回答
  •  情深已故
    2020-12-22 01:04

    Parametrized builds provide those parameters as environmental variables, like $PARAM_NAME. Use your favorites gradle method of getting environmental variables, like System.getenv('PARAM_NAME') or environmentString = "$System.env.PARAM_NAME"

提交回复
热议问题