Skip to content

ci: adopt Conventional Commits and automate releases with release-plz - #96

Open
felipebalbi wants to merge 4 commits into
OpenDevicePartnership:mainfrom
felipebalbi:docs/agents-and-release-plz
Open

felipebalbi wants to merge 4 commits into
OpenDevicePartnership:mainfrom
felipebalbi:docs/agents-and-release-plz

Conversation

@felipebalbi

@felipebalbi felipebalbi commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor
  • Add release-plz automation using crates.io Trusted Publishing.
  • Document Conventional Commits, squash merges, and agent guidance.
  • Link contributor and agent documentation from the README.

Docs and CI only; no crate behavior changes.

Repository rulesets were updated separately to allow release-plz branches
and version tags.

Before the first automated release, configure crates.io Trusted Publishing
for bq40z50-rx: owner OpenDevicePartnership, repository bq40z50,
workflow release-plz.yml.

Verification: revision tests (172 combined), Clippy, embedded-target check,
cargo-deny, cargo-vet, formatting, and package contents checked.

@felipebalbi felipebalbi changed the title ci: automate releases with release-plz and pin project conventions ci: adopt Conventional Commits and automate releases with release-plz Oct 8, 2026
@felipebalbi
felipebalbi marked this pull request as ready for review October 8, 2026 20:33
@felipebalbi
felipebalbi requested a review from a team as a code owner October 8, 2026 20:33
@felipebalbi
felipebalbi requested review from chchongmsft, colindonahue, seanbrns and thdesil and a balanced review from Copilot and removed request for Copilot October 8, 2026 20:33
@felipebalbi

Copy link
Copy Markdown
Contributor Author

@copilot rebase on top of the main branch.

@felipebalbi

Copy link
Copy Markdown
Contributor Author

@copilot rebase on top of the main branch.

Well, I guess that doesn't work 🤣

Records the decisions that were argued once in this repository and
should not be re-argued: the .ddsl manifests and their byte-identical
regeneration contract, the per-revision test macro and why a cfg inside
it is wrong, the deliberate PEC asymmetry between read_with_retries and
mac_read_with_retries, the data flash invariants, why the semver job was
removed, and the known TRM self-contradictions that are not driver bugs.

Also pins the verification expectations an agent cannot infer: the full
feature matrix including the multi-revision builds CI never runs, and
the requirement to mutation-test a fix before claiming it works.

Assisted-by: opencode:claude-opus-5
Adds release-plz.toml and the two-job release-plz workflow, modelled on
the tmp108, ina4230 and bq25773 configurations.

Publishing uses crates.io Trusted Publishing, so no registry token is
stored here. The crate is bq40z50-rx while the repository is bq40z50, so
the trust relationship must be configured at
crates.io/crates/bq40z50-rx/settings against repository bq40z50 and
workflow release-plz.yml before the first automated publish.

semver_check = true puts cargo-semver-checks on the release pull request,
which is why check.yml no longer has a semver job: on a feature branch
Cargo.toml still carries the last published version, so the check fails
every pull request that makes a breaking change.

Four branch rulesets were adjusted to let this run: release-plz-* is
excluded from both "Disable Branch Creation" and "Branch Protection",
the creation rule was removed from "Tag Protection", and a new "Tag
Creation Namespace" ruleset blocks every tag namespace except v*.

Assisted-by: opencode:claude-opus-5
CONTRIBUTING.md replaces the generic "use meaningful commit messages"
guidance with the Conventional Commits v1.0.0 rules, the allowed types,
the breaking-change format, and the TRM citation rule.

It also corrects a statement that was the opposite of how the repository
is configured. It claimed "We disabled squashing of commit"; merging is
squash-only and allow_merge_commit is false. The new section explains
the consequence: the pull request title becomes the only commit message
on main, so it must itself be a valid Conventional Commit, must carry !
if any commit on the branch is breaking, and must list every Closes #N
in the description because footers inside squashed commits do not fire.

README.md gains a pointer to both documents. The link is absolute
because lib.rs embeds the README as rustdoc, where relative links do not
resolve.

Assisted-by: opencode:claude-opus-5
The squash commit is the pull request title *and* description
(squash_merge_commit_title: PR_TITLE, squash_merge_commit_message:
PR_BODY), and release-plz parses both. Saying the title alone drives the
changelog and the version bump was wrong: a BREAKING CHANGE: footer or a
Closes #N in the description is read normally.

What is actually lost is the branch's own commit messages, because the
body comes from PR_BODY rather than COMMIT_MESSAGES. The rule for
authors is unchanged - aggregate footers into the description - but the
reason is now stated correctly.

Also notes why both the ! and the footer are required even though either
alone bumps the version: the ! is what shows up in git log --oneline and
the changelog heading, the footer is what explains the migration.

Assisted-by: opencode:claude-opus-5
Copilot AI balanced review requested due to automatic review settings October 8, 2026 20:41
@felipebalbi
felipebalbi force-pushed the docs/agents-and-release-plz branch from f62c713 to 108072d Compare October 8, 2026 20:41
@felipebalbi
felipebalbi enabled auto-merge (squash) October 8, 2026 20:41

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The release setup is coherent and verified, with only a non-blocking concurrency-comment correction identified.

1 open finding
What changed in this PR

Adds Conventional Commit guidance and automated crate releases using release-plz.

Changes:

  • Documents contributor and AI-agent workflows.
  • Adds Trusted Publishing release automation.
  • Links contribution guidance from the README.
File Description
release-plz.toml Configures versioning, changelogs, publishing, and releases.
.github/​workflows/​release-plz.yml Automates release PRs and publication.
CONTRIBUTING.md Defines commit, PR, and release conventions.
AGENTS.md Records repository-specific engineering guidance.
README.md Links contributor and agent documentation.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread .github/workflows/release-plz.yml Resolved
@felipebalbi

Copy link
Copy Markdown
Contributor Author

Ping?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants