Skip to content

ci(fix): modernise CI and remove warnings #83

ci(fix): modernise CI and remove warnings

ci(fix): modernise CI and remove warnings #83

Workflow file for this run

---
name: CI
'on': [push, pull_request]
env:
toolchain: nightly-2022-11-03
jobs:
clippy:
name: clippy
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
with:
submodules: "true"
- name: toolchain
uses: dtolnay/rust-toolchain@nightly
with:
toolchain: ${{ env.toolchain }}
components: rustfmt, clippy
- name: Cache rust dependencies
uses: Swatinem/rust-cache@v2
- name: cargo fmt
run: |
cargo +${{ env.toolchain }} fmt --all -- --check
- name: Install cargo-lints
run: |
cargo install cargo-lints
- name: Clippy check (with lints)
run: |
cargo lints clippy --all-targets --all-features
build:
name: build
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
with:
submodules: "true"
- name: toolchain
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
- name: Cache rust dependencies
uses: Swatinem/rust-cache@v2
- name: cargo build
run: |
cargo build --release
test:
name: test
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
with:
submodules: "true"
- name: toolchain
uses: dtolnay/rust-toolchain@stable
with:
toolchain: stable
- name: Cache rust dependencies
uses: Swatinem/rust-cache@v2
- name: cargo test
run: |
cargo test