-
Notifications
You must be signed in to change notification settings - Fork 0
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
Allow setting major version #15
Conversation
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.
The code looks correct, but the explicit major version silently overriding the three implicit methods seems like a potential source of hard-to-debug issues. For instance, when a new vN+1
branch is started and the user forgets to increment major-version
, won't it silently release vN? Would it be clearer for the user to decide on one approach?
The implicit part is still needed to generate reasonable version numbers i.e. if the last release was For real releases this has no impact as tags are taken as-is and there's no implicit behaviour. This only affects automated pre-releases. |
My suggestion would be to run the implicit part to determine the correct version, then check if the major versions match (if |
I think we could print a warning, but an error would be very disruptive as the issue is that the inferred major version is |
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.
LGTM pending some logging of how the version was determined, and if there was a discrepancy between explicit and implicit.
- Avoid showing logs during tests.
This PR has been shipped in release v1.6.0. |
This ensures the major version always matches the major version generated into the makefile too - based on the .ci-mgmt.yaml config. This is much more predictable behaviour than inferring from the branch name or PR labels. This utilises the new feature pulumi/provider-version-action#15, released in v1.6.0 of pulumi/provider-version-action
This ensures the major version always matches the major version generated into the makefile too - based on the .ci-mgmt.yaml config. This is much more predictable behaviour than inferring from the branch name or PR labels. This utilises the new feature pulumi/provider-version-action#15, released in v1.6.0 of pulumi/provider-version-action
This ensures the major version always matches the major version generated into the makefile too - based on the .ci-mgmt.yaml config. This is much more predictable behaviour than inferring from the branch name or PR labels. This utilises the new feature pulumi/provider-version-action#15, released in v1.6.0 of pulumi/provider-version-action
This ensures the major version always matches the major version generated into the makefile too - based on the .ci-mgmt.yaml config. This is much more predictable behaviour than inferring from the branch name or PR labels. This utilises the new feature pulumi/provider-version-action#15, released in v1.6.0 of pulumi/provider-version-action Stacked on #1363
Fixes #13
The inference of the major version can currently lead to some unexpected results. Add an option to pass in the expected major version to this action to ensure the major version is the desired value.
The only exception where the major version is ignored is when pushing tags. Tags are expected to be the exact version to publish, so we don't do any kind of inferrence there.