New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[JENKINS-22126] override build parameters only when explicitly requested #26
Conversation
@@ -164,6 +173,7 @@ public EnvInjectJobProperty newInstance(StaplerRequest req, JSONObject formData) | |||
JSONObject onJSONObject = (JSONObject) onObject; | |||
envInjectJobProperty.setKeepJenkinsSystemVariables(onJSONObject.getBoolean("keepJenkinsSystemVariables")); | |||
envInjectJobProperty.setKeepBuildVariables(onJSONObject.getBoolean("keepBuildVariables")); | |||
envInjectJobProperty.setKeepBuildVariables(onJSONObject.getBoolean("overrideBuildParameters")); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a typo. I suppose you should call setOverrideBuildParameters
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indeed
plugins » envinject-plugin #43 UNSTABLE |
From my side, it makes sense to leave the legacy behavior by default. |
…ted on configuration
envinject "legacy" behavior is buggy : it applies even user didn't configure anything on job, it overrides parameters that is contra-intuitive. I would expect a dozen of users to rely on this |
plugins » envinject-plugin #44 UNSTABLE |
Thank you for a pull request! Please check this document for how the Jenkins project handles pull requests |
@ndeloof |
[JENKINS-22126] override build parameters only when explicitly requested
add a configuration option to explicitly ask envinject to override build parameters. Don't override by default and don't override when envinject isn't used on jobs.