30 lines
683 B
YAML
30 lines
683 B
YAML
name: Full Rust codebase checks
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
RUSTFLAGS: "-D warnings"
|
|
|
|
on:
|
|
workflow_call:
|
|
|
|
jobs:
|
|
run:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- run: rustup toolchain install stable --profile minimal
|
|
- uses: Swatinem/rust-cache@v2
|
|
|
|
- run: cargo check --workspace --examples --tests --benches --bins
|
|
- run: cargo fmt -- --check
|
|
- run: cargo clippy --workspace --all-targets
|
|
|
|
check_c_warnings:
|
|
name: Check C warnings
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Make C library to check that it's able to compile without warnings
|
|
run: make -j CFLAGS="-Werror"
|