Improve release script#2127
Open
JeanChristopheMorinPerso wants to merge 10 commits into
Open
Conversation
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
…rm before releasing Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR modernizes the Rez release workflow by replacing the release script’s step flags with subcommands and updating the release documentation to match the new process.
Changes:
- Adds
changelog,tag, andreleasesubcommands torelease-rez.py. - Adds automatic PR discovery and GitHub release creation preview/confirmation.
- Updates
RELEASE.mdwith the revised release procedure.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 8 comments.
| File | Description |
|---|---|
release-rez.py |
Reworks release automation, changelog generation, tagging, and GitHub release creation. |
RELEASE.md |
Documents the new subcommand-based release workflow. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| if __name__ == "__main__": | ||
| parser = argparse.ArgumentParser() | ||
| parser.add_argument("--dry-run", help="Don't run any destructive actions") |
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
…I arguments Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.com>
Signed-off-by: Jean-Christophe Morin <jean_christophe_morin@hotmail.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.
This PR changes the release script to better reflect my current workflow. It is more opinionated and also will try to prevent as many mistakes as possible.
I changed the interface to be more user friendly. It makes use of subcommands:
release-rez.py changeloggenerates the changelog based on upstream commits. It gets the commits between the previous release and HEAD and for each commits gets the corresponding PR. The output is the same as before.release-rez.py tagsame as before.release-rez.py releasecreates the release. It now properly formats the release notes to be compatible with what GH expects. It also now prints a preview of the release and asks you if you want to actually create the release. This gives us an opportunity to catch any mistakes before it's too late.The
pushstep is gone. It was not useful IMO.In terms of robustness, the checks for remotes was augmented to do this:
This removes a few footguns with the previous version of the script.
Lastly, I updated the release instructions to match the new script.
I believe that with these changes in place, the release process has been simplified and most importantly, the footguns have been removed. This will hopefully lead to streamlined releases without the additional stress caused by the previous script.
I used some help from an LLM to create this PR. Mostly for the regexes and the GH API calls. Corresponding threads: