Skip to content

Improve release script#2127

Open
JeanChristopheMorinPerso wants to merge 10 commits into
AcademySoftwareFoundation:mainfrom
JeanChristopheMorinPerso:improve_release_script
Open

Improve release script#2127
JeanChristopheMorinPerso wants to merge 10 commits into
AcademySoftwareFoundation:mainfrom
JeanChristopheMorinPerso:improve_release_script

Conversation

@JeanChristopheMorinPerso
Copy link
Copy Markdown
Member

@JeanChristopheMorinPerso JeanChristopheMorinPerso commented Jun 1, 2026

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 changelog generates 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 tag same as before.
  • release-rez.py release creates 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 push step is gone. It was not useful IMO.

In terms of robustness, the checks for remotes was augmented to do this:

  • If there is more than one remote, print an error and exit.
  • If there is only one remote but its name is not origin, print an error and exit.

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:

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>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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, and release subcommands to release-rez.py.
  • Adds automatic PR discovery and GitHub release creation preview/confirmation.
  • Updates RELEASE.md with 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.

Comment thread release-rez.py
Comment thread release-rez.py
Comment thread release-rez.py
Comment thread release-rez.py Outdated

if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument("--dry-run", help="Don't run any destructive actions")
Comment thread release-rez.py Outdated
Comment thread release-rez.py Outdated
Comment thread RELEASE.md Outdated
Comment thread release-rez.py
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>
@JeanChristopheMorinPerso JeanChristopheMorinPerso added this to the Next milestone Jun 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants