Skip to content

Commit

Permalink
Comprehensive CI
Browse files Browse the repository at this point in the history
  • Loading branch information
LDeakin committed Jun 15, 2024
1 parent edac662 commit 404ecef
Showing 1 changed file with 36 additions and 4 deletions.
40 changes: 36 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,49 @@ env:
CARGO_TERM_COLOR: always

jobs:
build:
strategy:
matrix:
toolchain: ["stable", "1.75", "beta", "nightly"]
features: ["--features \"\"", "--all-features", "--no-default-features"]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update && sudo apt install -y cmake clang-15
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
- uses: Swatinem/rust-cache@v2
- run: cargo build ${{ matrix.features }}
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update && sudo apt install -y cmake clang-15
- uses: dtolnay/rust-toolchain@stable
- run: rustup component add rustfmt clippy
- uses: Swatinem/rust-cache@v2
- run: cargo build --all-features
- run: cargo test --all-features
- run: cargo check # default features
- run: cargo check --no-default-features
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update && sudo apt install -y cmake clang-15
- uses: dtolnay/rust-toolchain@stable
- run: rustup component add rustfmt
- uses: Swatinem/rust-cache@v2
- run: cargo fmt --all -- --check
clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: sudo apt update && sudo apt install -y cmake clang-15
- uses: dtolnay/rust-toolchain@stable
- run: rustup component add clippy
- uses: Swatinem/rust-cache@v2
- run: cargo clippy --all-features -- -D warnings
semver:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check semver
uses: obi1kenobi/cargo-semver-checks-action@v2

0 comments on commit 404ecef

Please sign in to comment.