Skip to content

initial commit

initial commit #4

Workflow file for this run

name: ci
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
env:
CARGO_TERM_COLOR: always
jobs:
ci:
name: ci
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
rust: [stable, beta, nightly, 1.80.0] # stable, beta, nightly, and MSRV
flow: [test]
exec: ["test", "test --release"]
include:
- rust: stable
flow: deny
exec: ''
- rust: stable
flow: fmt
exec: fmt --all -- --check
- rust: stable
flow: clippy
exec: clippy --bins -- -D warnings
steps:
- name: checkout code
uses: actions/checkout@v5
- name: install rust toolchain
uses: dtolnay/rust-toolchain@master
if: matrix.exec != ''
with:
toolchain: ${{ matrix.rust }}
components: clippy, rustfmt
- name: cache rust toolchain
uses: Swatinem/rust-cache@v2
if: matrix.exec != ''
- name: cargo deny
uses: EmbarkStudios/cargo-deny-action@v2
if: matrix.flow == 'deny'
- name: cargo ${{ matrix.flow }}
run: cargo ${{ matrix.exec }}
if: matrix.exec != ''