From df394f3a5bef51145108a045848ecfd7a8edea03 Mon Sep 17 00:00:00 2001 From: Sagnik Ghosh Date: Sun, 16 Aug 2026 21:09:52 +0530 Subject: [PATCH] ci: add minimal compile gate for PRs and main MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The release workflow was the repo's only build check, so uncompilable merges could land on main unnoticed — v1.6.8 alone shipped three separate "repair main" fixes. Gate every PR (and main push) with cargo check --locked --all-targets on ubuntu: compiles lib, bins, tests, and benches without running anything. Verified green on current main locally. Generated-By: PostHog Desktop Task-Id: e7b264f3-e943-4463-a70c-be3d056017ab --- .github/workflows/ci.yml | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..f9b35ab --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,37 @@ +name: CI + +# Minimal compile gate for PRs and main. Until this existed, the release +# workflow was the repo's only build check, so uncompilable merges could land +# on main unnoticed — v1.6.8 alone shipped three separate "repair main" fixes. +# +# Deliberately just `cargo check`: fast enough to gate every PR, and it +# compiles the lib, bins, tests, and benches without running anything. + +on: + pull_request: + push: + branches: [main] + +permissions: + contents: read + +concurrency: + group: ci-${{ github.ref }} + cancel-in-progress: true + +jobs: + check: + name: cargo check + runs-on: ubuntu-22.04 + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install Rust toolchain + uses: dtolnay/rust-toolchain@stable + + - name: Cache cargo + uses: Swatinem/rust-cache@v2 + + - name: Check (lib, bins, tests, benches) + run: cargo check --locked --all-targets