Skip to content

cargo: MSRV and GitHub Actions #84

cargo: MSRV and GitHub Actions

cargo: MSRV and GitHub Actions #84

Workflow file for this run

name: Cargo
on:
push:
branches: [master]
pull_request:
branches: [master]
jobs:
build:
name: MSRV
strategy:
matrix:
os: ['ubuntu-latest', 'macos-latest']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v5
- uses: dtolnay/[email protected]
with:
components: rustfmt, clippy
- name: Cache cargo registry
uses: actions/cache@v4
with:
path: ~/.cargo/registry
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
- name: Build
run: cargo build --verbose
env:
RUSTFLAGS: -D warnings
- name: Clippy
run: cargo clippy --all --tests
env:
RUSTFLAGS: -D warnings
- name: Test
run: cargo test --all --verbose
- name: Formatting
run: cargo fmt --all -- --check
- name: Docs
run: cargo doc --workspace --no-deps
env:
RUSTFLAGS: -D warnings
build-serde:
name: Serde Build
strategy:
matrix:
os: ['ubuntu-latest', 'macos-latest']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v5
- uses: dtolnay/[email protected]
- name: Build
run: cargo build --verbose --features serialize
env:
RUSTFLAGS: -D warnings
- name: Test
run: cargo test --all --verbose --features serialize,arbitrary
build-bincode:
name: Bincode Build
strategy:
matrix:
os: ['ubuntu-latest', 'macos-latest']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v5
- uses: dtolnay/[email protected]
- name: Build
run: cargo build --verbose --features serialize
env:
RUSTFLAGS: -D warnings
- name: Test
run: cargo test --all --verbose --features bincode,arbitrary
no-std:
name: no-std
strategy:
matrix:
os: ['ubuntu-latest', 'macos-latest']
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v5
- uses: dtolnay/[email protected]
- name: Build
run: cargo build --verbose --no-default-features
env:
RUSTFLAGS: -D warnings
- name: Test
run: cargo test --all --verbose --no-default-features