From 3fb6fa995de3d4c208c7aa1f43ade2e0201ff8c2 Mon Sep 17 00:00:00 2001 From: Josh Date: Mon, 21 Apr 2025 20:11:16 -0500 Subject: [PATCH] revert pushing of tags for bumpver in favor of release PR --- noxfile.py | 27 +++++++++++++++------------ pyproject.toml | 2 +- 2 files changed, 16 insertions(+), 13 deletions(-) diff --git a/noxfile.py b/noxfile.py index a4c727b..50452e6 100644 --- a/noxfile.py +++ b/noxfile.py @@ -260,6 +260,21 @@ def update_uvlock(session): ) +@nox.session(requires=["cog", "process_docs", "update_changelog", "update_uvlock"]) +def release(session): + version = get_version(session) + session.run("git", "checkout", "-b", f"release/v{version}") + command = ["uv", "run", "bumpver", "update"] + if session.posargs: + args = [] + for arg in session.posargs: + if arg: + args.extend(arg.split(" ")) + command.extend(args) + session.run(*command) + session.run("gh", "pr", "create", "--fill", "--head") + + def get_version(session): command = ["uv", "run", "bumpver", "update", "--dry", "--no-fetch"] if session.posargs: @@ -273,17 +288,5 @@ def get_version(session): return to_pep440(match.group(1)) if match else None -@nox.session(requires=["cog", "process_docs", "update_changelog", "update_uvlock"]) -def release(session): - command = ["uv", "run", "bumpver", "update"] - if session.posargs: - args = [] - for arg in session.posargs: - if arg: - args.extend(arg.split(" ")) - command.extend(args) - session.run(*command) - - if __name__ == "__main__": nox.main() diff --git a/pyproject.toml b/pyproject.toml index a661c8f..32701ff 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -81,7 +81,7 @@ commit = true commit_message = ":bookmark: bump version {old_version} -> {new_version}" current_version = "5.2.0-alpha" push = true -tag = true +tag = false version_pattern = "MAJOR.MINOR.PATCH[-TAG[.NUM]]" [tool.bumpver.file_patterns]