version bump #10
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: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: Swatinem/rust-cache@v2 | |
with: | |
cache-on-failure: true | |
- name: Install rust | |
uses: hecrj/setup-rust-action@v1 | |
with: | |
rust-version: 1.76.0 | |
- name: Install clippy and rustfmt | |
run: | | |
rustup component add clippy | |
rustup component add rustfmt | |
- name: Format | |
run: | | |
cargo fmt -- --check | |
- uses: actions/cache@v2 | |
with: | |
path: | | |
~/.cargo/registry | |
~/.cargo/git | |
target | |
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} | |
- name: Lint | |
run: | | |
cargo clippy --all-targets --locked --release -- -D clippy::all | |
- name: Build | |
run: cargo build --verbose | |
- name: Run tests | |
run: cargo test --verbose |