diff --git a/.gitea/workflows/checker-check.yml b/.gitea/workflows/checker-check.yml new file mode 100644 index 0000000..a6ce325 --- /dev/null +++ b/.gitea/workflows/checker-check.yml @@ -0,0 +1,53 @@ +name: checker check + +# Builds and lints the Rust implementation crates under crates/ (the rule-based +# checker that "stands in Lean's position" at product runtime). +# +# Like spec-check, this is an INTERNAL gate on the implementation's own health +# (does it build, pass its tests, satisfy clippy + rustfmt?). It is NOT a +# spec-to-implementation conformance gate — implementations align to the Lean +# contract by human review, not by CI. See the repo README. + +on: + push: + pull_request: + workflow_dispatch: + +jobs: + checker-check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v5 + + - name: Install Rust toolchain (stable + clippy + rustfmt) + uses: dtolnay/rust-toolchain@stable + with: + components: clippy, rustfmt + + - name: Cache cargo registry + build + uses: actions/cache@v4 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: cargo-${{ runner.os }}-${{ hashFiles('Cargo.lock') }} + restore-keys: | + cargo-${{ runner.os }}- + + # Fonts for typst compilation (WU-4 onward): the engineering files are + # CJK-heavy, so the compile-check / build tests need a CJK font present. + # Harmless before those crates exist. + - name: Install CJK fonts + run: | + sudo apt-get update + sudo apt-get install -y fonts-noto-cjk + + - name: Format check + run: cargo fmt --all --check + + - name: Clippy (deny warnings) + run: cargo clippy --all-targets --all-features -- -D warnings + + - name: Test + run: cargo test --all-features --workspace