Repository navigation
chore: adopt the release standard - #99
Open
crcatala-vps wants to merge 2 commits into
Open
crcatala-vps wants to merge 2 commits into
crcatala-vps wants to merge 2 commits into
Conversation
monarch --version now prints `monarch X.Y.Z (sha7 YYYY-MM-DD)`, with `-dirty` for a build from an uncommitted tree. A checkout reads git; an installed wheel reads the release-standard _build_info.json stamp. `monarch update [--check] [--force]` updates the CLI with the method it was installed with (source checkout, uv tool, pipx, pip, or mise) through the release-standard cli_meta module. Update is classified with a new additive local_install_change effect so it never implies mutation authorization. The capabilities manifest fixture is regenerated for the new command. Co-authored-by: Christian Catalan <crcatala@gmail.com>
Add the canonical release-standard scripts (prep-release, check-changelog, build_info) plus a project-owned bump script and Makefile target. Release flow now refuses a dirty tree, a branch other than main, HEAD != origin/main, an existing tag, or an empty Unreleased section; smoke-install stamps the build, checks that the wheel and sdist ship the stamp, and verifies the exact --version line of both console entry points. release.sh refuses to tag when the stamp is not HEAD and still publishes to PyPI separately, last. Move the release guide to the repository root, keep docs/RELEASING.md as a pointer, and rewrite the README install section with registry installs, a from-source section, and the update command. Co-authored-by: Christian Catalan <crcatala@gmail.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.
Summary
Applies the shared release standard to monarch-cli: canonical release scripts, a
bumptarget, the standard--versionline, amonarch updatecommand, and an Install section with a from-source path. Version stays 0.2.1; no release or tag was created.What changed
scripts/prep-release.shscripts/check-changelog.shscripts/build_info.pymonarch --version/-vnow printsmonarch X.Y.Z (sha7 YYYY-MM-DD), with-dirtyfor an uncommitted tree. A checkout reads git; a wheel/sdist carries_build_info.jsonso installed copies print the same line.scripts/smoke_install.shstamps before building, verifies the stamp ships in both artifacts, and checks the exact line for both entry points.monarch update [--check] [--force]wired through the release-standardcli_metamodule. It detects checkout /uv tool/pipx/pip/miseinstalls, prints commands before running them, refuses a dirty or non-maincheckout, and reports exit codes0/1/2for--check. Update is classified with a new additivelocal_install_changeeffect, so it never implies--allow-mutations.make bump VERSION=X.Y.Z(newscripts/bump.sh) updates__init__.py,pyproject.toml,uv.lock, moves Unreleased to a dated section, updates comparison links, and commitschore: release vX.Y.Z. It refuses a dirty tree, non-main, an existing tag, or an empty Unreleased section.scripts/release.shnow requires a cleanmainatHEAD == origin/main, refuses an existing tag, and refuses to tag when the build stamp is notHEAD. Dry runs warn instead of refusing so they are usable on a feature branch.dist/(uv run twine upload dist/*), with the TestPyPI rehearsal preserved.RELEASING.md(the old page moved;docs/RELEASING.mdis now a redirect), README## Installrewritten with registry installs, From source, and Updating, plusupdateindocs/commands.mdand the new effect indocs/capabilities.md.tests/test_cli_meta.py(version-line formatting, CLI line, update flag/exit-code wiring); updated the capabilities fixture and inventory tests.What was kept that differs from the standard, and why
-Vstays--verbose;--versionstays-v. The repo already documents and tests these global flags, and they are part of the capabilities manifest. Changing-Vto mean version would be a breaking CLI change unrelated to this PR.--version/-vprint the standard line.monarch(the executable), while the distribution andcapabilities.cli.namestaymonarch-cli.twine, separate last step) and TestPyPI rehearsal is preserved;scripts/release.shstill never publishes, and the build still goes through the singlemake smoke-installtarget used by CI, prepublish, and release.scripts/build_info.pyis excluded fromruff(extend-exclude) so it stays byte-identical to the template;cli_meta.pywas adapted only for the repo's strict mypy/ruff settings.docs/RELEASING.mdkept as a redirect instead of deleting it, so existing links keep working.__init__.py/pyproject.toml/uv.lock, capabilities-fixture contract, packaged schema artifact checks, both console entry points, metadata-warning scan,twine check, and README rendering.Verification
COLUMNS=200 make verifymake prepublishsmoke-install+twine check dist/*+readme_rendereruv run monarch --versionmonarch 0.2.1 (ed28de7 2026-10-27)(this commit)uv run monarch-cli --versionmonarch 0.2.1 (ed28de7 2026-10-27)uv run monarch update --checkmonarch is up to date (ed28de7).exit 0make release-dryv0.2.1and the GitHub Release, no tag/release created (warns: dry run on a feature branch,HEAD != origin/main, andv0.2.1already exists because the version was intentionally not bumped)make bump VERSION=9.9.9in a throwaway clone onmainuv.lock, committedchore: release v9.9.9(not run in this repo)python3 .../audit.py .Note:
tests/commands/test_auth.py::test_status_human_readable_shows_file_pathfails locally whenCOLUMNSis unset (rich wraps the path); it passes withCOLUMNS=200, passes onmainwith the same setting, andmainCI is green. No release, tag, publish, or merge was performed.