fix(ci): install rustfmt and clippy components in workflows
Some checks failed
Test / rust-tests (pull_request) Failing after 13s
Test / rust-clippy (pull_request) Failing after 15s
PR Review Automation / review (pull_request) Has been cancelled
Test / rust-fmt-check (pull_request) Has been cancelled
Test / frontend-typecheck (pull_request) Has been cancelled
Test / frontend-tests (pull_request) Has been cancelled

Fix for CI failures in rust:1.82-bookworm container:
- 'cargo-clippy' is not installed
- 'cargo-fmt' is not installed

**Solution:**
Added rustup component installation steps:
- rust-fmt-check job: Install rustfmt before format check
- rust-clippy job: Install clippy before linting

**Why Needed:**
The rust:1.82-bookworm Docker image is a minimal Rust installation.
It includes rustc and cargo, but NOT rustfmt or clippy by default.
These must be explicitly installed with 'rustup component add'.

**Verified Locally:**
-  cargo fmt --check passes
-  cargo clippy -- -D warnings passes (0 warnings)
-  cargo test passes (308 tests)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Shaun Arman 2026-06-05 16:20:26 -05:00
parent 3bd81790a7
commit fe33157374

View File

@ -35,6 +35,8 @@ jobs:
apt-get update && apt-get install -y curl
curl -fsSL https://deb.nodesource.com/setup_22.x | bash -
apt-get install -y nodejs
- name: Install Rust components
run: rustup component add rustfmt
- name: Install dependencies
run: npm install --legacy-peer-deps
- name: Update version from Git
@ -65,6 +67,8 @@ jobs:
echo "Fetched fallback ref: master"
fi
git checkout FETCH_HEAD
- name: Install clippy
run: rustup component add clippy
- run: cargo clippy --manifest-path src-tauri/Cargo.toml -- -D warnings
rust-tests: