From 5f5fead50cef2124e9ddd8966c3ace0a98c9a94b Mon Sep 17 00:00:00 2001 From: Thales <> Date: Mon, 17 Aug 2026 23:05:52 +0100 Subject: [PATCH] Add an on-demand Windows Rust check on the self-hosted runner Companion to macos-check.yml. Justified twice over in one session: first by finding pre-existing macOS-only clippy issues nothing had ever caught, then for real when download_file silently lost its #[cfg(unix)] gate and shipped a broken Windows build in v0.11.1's first release attempt - undetected by ci.yml (100% ubuntu-latest) or macos-check.yml (macOS also satisfies unix, so it never exercised the Windows-only code path either). Same shape as macos-check.yml: build/clippy/test only, workflow_dispatch only, never touches packaging or uploads. --- .github/workflows/windows-check.yml | 56 +++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 .github/workflows/windows-check.yml diff --git a/.github/workflows/windows-check.yml b/.github/workflows/windows-check.yml new file mode 100644 index 0000000..630500e --- /dev/null +++ b/.github/workflows/windows-check.yml @@ -0,0 +1,56 @@ +name: Windows Rust Check + +# Manual only -- not on every PR/push, to keep the self-hosted runner's load +# and cost unchanged from today. Companion to macos-check.yml: ci.yml (which +# does run on every PR) is 100% ubuntu-latest, so nothing behind +# #[cfg(windows)] -- or, as it turned out, code that lost a #[cfg(unix)] gate +# and started compiling on Windows by accident -- has ever had a real +# compiler pass before merging. That exact gap shipped a broken Windows +# build in v0.11.1's first release attempt. +on: + workflow_dispatch: + +permissions: {} + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + check: + # Runner must have rustup and the MSVC toolchain (same requirements as + # windows-release.yml, which this intentionally does not replace -- this + # only builds/checks, never packages or uploads anything). + runs-on: [self-hosted, windows, x64] + timeout-minutes: 30 + defaults: + run: + shell: bash + working-directory: desktop/src-tauri + steps: + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + + - name: cargo fmt --check + run: cargo fmt --check + + - name: cargo build + run: cargo build --tests + + - name: cargo clippy + # -A flags suppress pre-existing lints unrelated to this workflow's + # purpose (tracked separately, not introduced by whatever change this + # check is run against) so a real regression isn't lost in known noise. + # unused_variables (pip_pid) and needless_return are Windows-build-only + # findings from this workflow's first-ever run -- nothing has + # type-checked this target before, so they predate this workflow + # rather than being caused by it. + run: | + cargo clippy --tests -- -D warnings \ + -A clippy::derivable_impls \ + -A clippy::single_match \ + -A clippy::trim_split_whitespace \ + -A unused_variables \ + -A clippy::needless_return + + - name: cargo test + run: cargo test