This document summarizes the automated release process implementation for TrustLink.
- Trigger: Push to main branch
- Purpose: Automatically creates Release PRs based on conventional commits
- Actions:
- Analyzes commits since last release
- Determines semantic version bump (major/minor/patch)
- Creates PR that updates
Cargo.tomlandCHANGELOG.md - Generates changelog from commit messages
- Trigger: GitHub Release published
- Purpose: Builds and publishes WASM artifacts
- Actions:
- Checks out release tag
- Builds WASM contract
- Optimizes with
soroban contract optimize - Uploads both binaries to GitHub Release
- Creates release summary in GitHub Actions
- Trigger: PR opened or updated
- Purpose: Validates commit message format
- Actions:
- Checks PR title follows conventional commits
- Validates commit messages
- Blocks merge if validation fails
- Configures Release Please behavior
- Defines changelog sections and commit type mappings
- Specifies version file (
Cargo.toml) and changelog path
- Defines commit message validation rules
- Enforces conventional commits format
- Specifies allowed types, scopes, and format requirements
- Alternative semantic-release configuration (optional)
- Provides fallback release automation setup
- Comprehensive release process documentation
- Explains how automation works
- Provides troubleshooting guide
- Documents manual release procedures
- Detailed workflow guide for contributors and maintainers
- Commit message format with examples
- Version bumping scenarios
- Best practices and troubleshooting
- Added "Commit Message Conventions" section
- Explains conventional commits format
- Provides good/bad examples
- Documents automated release process
- Replaced manual release checklist with automated process
- Added quick reference for release workflow
- Links to detailed documentation
- Added commitlint hook for local commit validation
- Validates messages before commit is created
- Prevents invalid commits from being pushed
✅ Merging to main with feat/fix commits triggers release PR
- Release Please automatically creates PR when commits are merged
- PR is created within minutes of merge
- No manual action required
✅ Release PR updates version in Cargo.toml and CHANGELOG
- Version automatically bumped based on commit types
- CHANGELOG generated from commit messages
- Grouped by type (Features, Bug Fixes, etc.)
✅ Merging release PR creates GitHub Release
- Release is created automatically when Release PR is merged
- Git tag is created with version number
- Release notes are generated from changelog
✅ WASM artifact attached to release automatically
publish-releaseworkflow triggered on release creation- Both unoptimized and optimized WASM binaries built
- Artifacts automatically attached to GitHub Release
- File sizes and details included in release summary
✅ Commit message conventions documented in CONTRIBUTING.md
- Comprehensive guide with examples
- Explains all commit types and their impact
- Shows good and bad examples
- Documents scope usage
-
Create feature branch:
git checkout -b feat/your-feature
-
Commit with conventional format:
git commit -m "feat(storage): add dual indexing" -
Pre-commit validation:
- Commitlint validates message format
- Cargo fmt and clippy run
- Commit is blocked if validation fails
-
Push and open PR:
git push origin feat/your-feature
-
CI validation:
- Tests run
- Code quality checks pass
- Commit message validation passes
-
Merge to main:
- Use "Squash and merge" or "Create a merge commit"
- Do NOT use "Rebase and merge"
-
Release Please analyzes commits:
- Reads all commits since last release
- Determines version bump (major/minor/patch)
- Generates changelog from commit messages
-
Release PR is created:
- Updates
Cargo.tomlwith new version - Updates
CHANGELOG.mdwith formatted entries - PR is ready for review
- Updates
-
Maintainer reviews and merges:
- Check version bump is correct
- Review changelog entries
- Merge Release PR
-
GitHub Release is created:
- Git tag is created (e.g.,
v0.2.0) - GitHub Release is published
publish-releaseworkflow is triggered
- Git tag is created (e.g.,
-
WASM artifacts are built:
- Workflow checks out release tag
- Builds WASM contract
- Optimizes with soroban-cli
- Uploads both binaries to release
| Commits | Version Change | Example |
|---|---|---|
feat only |
Minor | 0.1.0 → 0.2.0 |
fix only |
Patch | 0.1.0 → 0.1.1 |
feat + fix |
Minor | 0.1.0 → 0.2.0 |
docs, test, chore only |
No release | — |
BREAKING CHANGE footer |
Major | 0.1.0 → 1.0.0 |
| Type | Purpose | Version Impact |
|---|---|---|
feat |
New feature | Minor |
fix |
Bug fix | Patch |
docs |
Documentation | None |
test |
Tests | None |
refactor |
Code refactoring | None |
perf |
Performance improvement | Patch |
chore |
Build, CI, dependencies | None |
.github/workflows/release-please.yml.github/workflows/publish-release.yml.github/workflows/validate-commits.ymlrelease-please-config.json.commitlintrc.json.releaserc.jsonRELEASE.mddocs/release-workflow.mdRELEASE_AUTOMATION_IMPLEMENTATION.md(this file)
.pre-commit-config.yaml(added commitlint hook)CONTRIBUTING.md(added commit conventions section)README.md(replaced manual release checklist)
-
Ensure all commits follow conventional format:
git log --oneline main..origin/main
-
Merge a commit with
feat:orfix:prefix to main -
Release Please will create a Release PR within minutes
-
Review and merge the Release PR
-
GitHub Release will be created automatically
-
WASM artifacts will be built and attached
-
Update local pre-commit hooks:
pre-commit install --install-hooks
-
Read CONTRIBUTING.md for commit conventions
-
Use conventional commit format for all commits
-
Monitor Release PRs and merge when ready
- Check commits follow conventional format
- Ensure at least one
featorfixcommit - Check Release Please workflow is enabled
- Review commit messages
- Check
release-please-config.jsonconfiguration - Verify commit types match expectations
- Check
publish-releaseworkflow logs - Verify soroban-cli installation succeeded
- Manually build and attach if needed
- Check commit message format
- Review
.commitlintrc.jsonrules - Fix message and try again
- Conventional Commits
- Semantic Versioning
- Release Please Documentation
- Commitlint Documentation
- CONTRIBUTING.md
- RELEASE.md
- docs/release-workflow.md
For questions or issues with the release process:
- Check RELEASE.md for detailed documentation
- Review docs/release-workflow.md for workflow guide
- See CONTRIBUTING.md for commit conventions
- Check GitHub Actions logs for workflow errors
- Open an issue on GitHub with details
Implementation Date: March 26, 2026 Status: Ready for use Maintainer: TrustLink Team