ci: Automate patch releases and pre-releases #3485
Merged
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.
This work by automatically pushing a new tag on main and release branches after each commit. The tag will be "devel" on main and the version from postgrest.cabal for release branches. The release workflow then runs as a tag pipeline, making the actual release.
For release branches, the tag will only be created if a tag for this version doesn't exist, yet. This means to actually make a new patch release, we still need to bump the version in postgrest.cabal. We can automate this later as part of our backport-bot.
Resolves #2006
Resolves #2997
This PR should support both nightly
devel
releases as well as patch releases on older branches. Before it will do the latter, though, it would need to be backported tov12
- or we'd need to make a minor release first. Either of the two will work.I have tested this as much as I can on the main branch of my personal fork. This doesn't fully go through the release, because I don't have all the pieces (github, docker, tokens, etc.) in place. I will now merge this to postgrest/main and then see what kind of adjustments we still need to make.