This document defines how ca9 versions, GitHub releases, and PyPI publishes are handled.
- Automated semantic versioning with Release Please
- Semantic PR title guardrails
- GitHub release and tag creation
- PyPI package build and publish from immutable release tags
-
Protect
main.- Require pull requests before merge.
- Require CI checks to pass.
- Prefer squash merges so the PR title becomes the release commit.
-
Use semantic PR titles.
- Workflow:
.github/workflows/pr-title.yml - Format:
<type>(<scope>): <subject> - Examples:
feat(inventory): add npm package-lock readerfix(scanner): preserve npm package namesdocs(release): document automated publishing
- Workflow:
-
Keep Release Please configured.
- Workflow:
.github/workflows/release.yml - Config:
tools/release/release-please-config.json - Manifest:
tools/release/.release-please-manifest.json
- Workflow:
-
Keep PyPI trusted publishing configured.
- Workflow file:
release.yml - Environment:
pypi - Package:
ca9
- Workflow file:
-
Prefer a dedicated release token.
- Preferred secret:
RELEASE_PLEASE_TOKEN - Fallback:
GITHUB_TOKEN - A dedicated token or GitHub App is better when release PRs must satisfy required status checks.
- Preferred secret:
Release Please is bootstrapped from the existing v0.3.1 GitHub release:
- Manifest version:
0.3.1 - Bootstrap SHA:
6f6b322ec407c8b3c6a9e1a52afba068ca809b59
This prevents Release Please from trying to create an already-existing v0.3.1
tag. Future releases are generated from commits after the bootstrap SHA.
- Contributors merge PRs to
mainwith semantic titles. - On push to
main, Release Please opens or updates a release PR. - Maintainers review and merge the Release Please PR.
- Release Please creates the
vX.Y.Ztag and GitHub release. - The same workflow builds and publishes from the generated tag.
The publish job checks that:
- the checked-out commit is the release tag commit,
- the release tag is reachable from
main, - the GitHub release exists,
pyproject.toml,src/ca9/__init__.py,tools/release/.release-please-manifest.json, and docs structured metadata all match the tag version.
feat-> minor bumpfix-> patch bumpBREAKING CHANGEfooter -> major bumpdocs,test,chore,ci, and similar maintenance commits normally do not create a release unless they include breaking-change metadata.
If publishing fails after the GitHub release was created:
- Fix the workflow, package metadata, or PyPI publishing setup.
- Re-run the failed publish job if the dist artifacts are still valid.
- Otherwise, manually dispatch
.github/workflows/release.ymlwithref=vX.Y.Zto rebuild and publish from the existing release tag. - Do not publish from a branch ref.