Repository navigation
Conversation
…ws#2380) When samconfig sets parameter_overrides_merge = true, a --parameter-overrides value given on the command line is merged per key with the samconfig value (command line wins) instead of replacing it. Default behaviour is unchanged. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When samconfig sets parameter_overrides_merge = true, a --parameter-overrides value given on the command line is merged per key with the samconfig value (command line wins) instead of replacing it. Default behaviour is unchanged.
Which issue(s) does this change fix?
#2380
Why is this change necessary?
--parameter-overrideson the command line replacesparameter_overridesfrom samconfig entirely. A CI job that needs to add one value (a commit SHA, a secret, a tag) has to repeat every value from the config file.(#7876 left this out because changing the default would not be backward compatible).
How does it address the issue?
Adds an opt-in samconfig key,
parameter_overrides_merge = true. When it is set and--parameter-overridesis given on the command line, the two are merged per key, with the command line winning. It is a callback on the shared--parameter-overridesoption, so it applies to every command that has that option. Documented indocs/sam-config-docs.md.What side effects does this change have?
None unless the key is set; the default behaviour is unchanged. The key exists only in samconfig (no new CLI flag), so it does not appear in
--helpor in the generated schema. The samconfig page in the AWS SAM Developer Guide would need the same addition.Mandatory Checklist
PRs will only be reviewed after checklist is complete
make prpassesmake update-reproducible-reqsif dependencies were changedBy submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
I used Claude to help write this change. I have reviewed and tested it.