Releasing Ito¶
This project uses:
- release-plz for release PRs, versioning, and crates.io publishing
- cargo-dist for GitHub Releases and cross-platform binaries/installers
How It Works¶
- Commits to
mainare analyzed by release-plz (conventional commits) - release-plz opens/updates a release PR with version bumps and
CHANGELOG.mdupdates (via git-cliff) - Merging the release PR causes release-plz to publish crates to crates.io and create a
vX.Y.Ztag - The tag triggers cargo-dist to:
- Build cross-platform binaries and installers
- Create/update the GitHub Release and upload assets
- Publishing the GitHub release triggers:
- release note polishing (optional)
- Homebrew formula update
- GitHub Pages docs deploy (builds
site/and publishes it)
GitHub Pages Prerequisite¶
The repository must have GitHub Pages configured to deploy from GitHub Actions:
- Repo Settings -> Pages -> Source = "GitHub Actions"
Commit Message Format¶
Use conventional commits to control version bumps:
| Prefix | Version Bump | Example |
|---|---|---|
feat: |
Minor (0.X.0) | feat: add new command |
fix: |
Patch (0.0.X) | fix: correct parsing error |
feat!: or BREAKING CHANGE: |
Major (X.0.0) | feat!: redesign API |
Other prefixes (docs:, chore:, refactor:, test:, ci:) don't trigger releases but are included in the changelog.
Manual Release Trigger¶
If you need to force (re)generation of the release PR, you can run release-plz locally:
This runs release-plz release-pr against the repo.
Emergency Manual Release¶
If you need to release without any automation:
Files Managed by Release Automation¶
Cargo.toml- workspace versionCHANGELOG.md- changelogrelease-plz.toml- release-plz configurationcliff.toml- git-cliff configurationdist-workspace.toml- cargo-dist configuration
Troubleshooting¶
Release PR not created¶
- Check that commits follow conventional commit format
- Verify the
Release-plzworkflow ran successfully
Version mismatch error in release workflow¶
- The tag version must match the version in
Cargo.toml - release-plz should keep these in sync automatically