1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
# CI gate for skillpack (design §7.4): fmt + clippy + full test suite on every
# PR; no PR merges without green CI.
#
# `--include-ignored` runs the Go + Ruby `#[ignore]`-gated round trips here
# because the ubuntu-latest runner ships those runtimes (the dev machine does
# not). Each ignored test self-skips via a runtime probe, so a missing runtime
# anywhere degrades the same way it does locally rather than failing.
name: CI
on:
push:
branches:
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# Install the exact toolchain pinned in rust-toolchain.toml so CI's
# fmt/clippy are byte-identical to local — a newer stable's fmt collapse
# rule can't pass one place and fail the other. `rust-toolchain.toml` is
# the single source of truth; this input must match its `channel` field.
- uses: dtolnay/rust-toolchain@master
with:
toolchain: '1.95.0'
components: 'rustfmt,clippy'
- uses: Swatinem/rust-cache@v2
- name: Install runtime prereqs (node, python, go, ruby)
run: |
sudo apt-get update
sudo apt-get install -y nodejs python3 golang ruby
- name: fmt --check
run: cargo fmt --check
- name: clippy --all-targets
run: cargo clippy --all-targets -- -D warnings
- name: test (incl. ignored runtime round trips)
run: cargo test --all-targets -- --include-ignored