Bump actions/checkout from 3 to 4 #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: push | |
jobs: | |
tests: | |
name: Tests (Rust ${{ matrix.rustup-toolchain }}, Ruby ${{ matrix.ruby-version }}) | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
rustup-toolchain: | |
- stable | |
- "1.51" | |
ruby-version: | |
- "2.6" | |
- "2.7" | |
- "3.0" | |
- "3.1" | |
- "3.2" | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v4 | |
- name: Set up Ruby and Rust | |
uses: oxidize-rb/actions/[email protected] | |
with: | |
rustup-toolchain: ${{ matrix.rustup-toolchain }} | |
ruby-version: ${{ matrix.ruby-version }} | |
cache-version: v2 | |
cargo-cache: true | |
- uses: Swatinem/rust-cache@v1 | |
- name: Run tests | |
run: cargo test | |
clippy: | |
name: Clippy | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v4 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
components: clippy | |
override: true | |
- uses: Swatinem/rust-cache@v1 | |
- name: Run Clippy | |
run: cargo clippy --no-deps -- -D warnings | |
rustfmt: | |
name: rustfmt | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v4 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
components: rustfmt | |
override: true | |
- name: Check formatting | |
run: cargo fmt --all -- --check |