Skip to content

Language-aware loop gate + launch-prep docs #102

Language-aware loop gate + launch-prep docs

Language-aware loop gate + launch-prep docs #102

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
RUSTFLAGS: "-D warnings"
RUST_BACKTRACE: 1
jobs:
fmt:
name: rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- run: cargo fmt --all -- --check
clippy:
name: clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2
- run: cargo clippy --all-targets --all-features -- -D warnings
test:
name: test (${{ matrix.os }} / ${{ matrix.toolchain }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
toolchain: [stable, "1.91"]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
- uses: Swatinem/rust-cache@v2
with:
key: ${{ matrix.os }}-${{ matrix.toolchain }}-v2
# Never cache `~/.cargo/bin/`. The rustup-installed `cargo` proxy
# there gets clobbered by a stale cache entry, breaking the next
# run with `error: unexpected argument 'build' found` (cargo is
# actually `rustup-init`). Hit us on macos-latest/1.91 — keep this off.
cache-bin: "false"
- run: cargo build --all-targets --locked
- run: cargo test --all-targets --locked
audit:
name: cargo-audit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- run: cargo install --locked cargo-audit
- run: cargo audit
deny:
name: cargo-deny
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- run: cargo install --locked cargo-deny
- run: cargo deny --all-features check
continue-on-error: true # advisories drift outpaces our review cadence