Crate collapse #7
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
# Rust template: https://github.com/actions/starter-workflows/blob/main/ci/rust.yml | |
# Resources: https://docs.github.com/en/actions | |
# Examples: https://github.com/actions/starter-workflows | |
# Process: make small changes, push them, check the Actions tab on github | |
# also see templates https://github.com/rust-github/template/tree/main/.github/workflows | |
name: Lint | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
env: | |
CARGO_TERM_COLOR: always # pretty colors | |
jobs: | |
clippy: | |
name: clippy | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
profile: minimal | |
components: clippy | |
override: true | |
- name: cargo clippy | |
run: cargo clippy --all | |
udeps: | |
name: udeps | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Rust | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: nightly | |
profile: minimal | |
override: true | |
- name: install udeps | |
run: cargo install --git https://github.com/est31/cargo-udeps --locked | |
- name: cargo udeps | |
run: cargo +nightly udeps | |
fmt: | |
name: fmt project | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
toolchain: | |
- nightly | |
steps: | |
- name: checkout repo | |
uses: actions/checkout@v4 | |
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }} | |
- run: rustup component add rustfmt | |
- run: cargo fmt --all -- --check |