Add GitHub Actions CI + release pipelines - #1
Merged
Conversation
CI (ci.yml): fmt + clippy + test on pull_request to master only. Runs on a single ubuntu-latest runner; all cargo commands use --locked to stay character-identical to local dev. No push:master trigger — master is guarded by PR review + branch protection, so re-running on merge is redundant. Release (release.yml): tag-driven (v*) native build matrix across linux-amd64, macos-arm64, macos-amd64, windows-amd64, then a publish job that verifies the git tag matches Cargo.toml version before uploading artifacts to a GitHub Release. Standard GitHub-hosted runners → free for public repositories. Also applies cargo fmt --all so the new fmt gate passes on first run. Co-authored by PeakBot!
3 tasks
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.
What
Adds two GitHub Actions workflows and applies
cargo fmt --allso the new fmt gate is green on first run.ci.yml— lint + checkspull_request→masteronly (nopush: master). Master is guarded by PR review/branch protection, so re-running CI on merge is redundant.ubuntu-latestrunner (stateless CLI logic isn't OS-specific).fmt --check+clippy -D warnings+test, all--lockedto stay character-identical to local dev.concurrencykeyed onhead_refso re-pushing a PR cancels the stale run.release.yml— build + publishv*tag.linux-amd64,macos-arm64,macos-amd64,windows-amd64(rustls → no system libs, no Docker/cross needed).publishjob verifies the git tag matchesCargo.tomlversion before uploading — turns silent tag/version drift into a loud one-line failure.softprops/action-gh-release@v2with auto-generated notes.Cost note 💸
mac & Windows standard GitHub-hosted runners are free for public repositories (confirmed in GitHub's billing docs). This matrix costs $0 as long as the repo stays public and we don't switch to larger runners (those are always billed).
Testing
Ran the exact CI gates locally on this branch — all green:
cargo fmt --all -- --check✓cargo clippy --all-targets --locked -- -D warnings✓cargo test --locked✓ (15 + 3 tests pass)Co-authored by PeakBot!