From 4ff33eaef585acc0977c390c0f52928f573dbd44 Mon Sep 17 00:00:00 2001 From: Kim Morrison <477956+kim-em@users.noreply.github.com> Date: Mon, 15 Sep 2025 11:41:17 +1000 Subject: [PATCH] feat: updates to release process for cslib (#10385) This PR updates the release checklist scripts to handle a corner case in Cslib. --- script/release_steps.py | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/script/release_steps.py b/script/release_steps.py index ffec0bf765..386e55fa0b 100755 --- a/script/release_steps.py +++ b/script/release_steps.py @@ -377,6 +377,17 @@ def execute_release_steps(repo, version, config): except subprocess.CalledProcessError as e: print(red("Tests failed, but continuing with PR creation...")) print(red(f"Test error: {e}")) + elif repo_name == "cslib": + run_command(f'perl -pi -e \'s/"v4\\.[0-9]+(\\.[0-9]+)?(-rc[0-9]+)?"/"' + version + '"/g\' lakefile.*', cwd=repo_path) + + # Update lean-toolchain in docs + print(blue("Updating docs/lean-toolchain...")) + docs_toolchain = "docs" / "lean-toolchain" + with open(docs_toolchain, "w") as f: + f.write(f"leanprover/lean4:{version}\n") + print(green(f"Updated docs/lean-toolchain to leanprover/lean4:{version}")) + + run_command("lake update", cwd=repo_path, stream_output=True) elif dependencies: run_command(f'perl -pi -e \'s/"v4\\.[0-9]+(\\.[0-9]+)?(-rc[0-9]+)?"/"' + version + '"/g\' lakefile.*', cwd=repo_path) run_command("lake update", cwd=repo_path, stream_output=True)