Skip to content

Fix new clippy check #43

Fix new clippy check

Fix new clippy check #43

Workflow file for this run

name: Check
on:
push:
branches:
- main
pull_request:
env:
CARGO_TERM_COLOR: always
defaults:
run:
# necessary for Windows
shell: bash
jobs:
fmt:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- run: cargo fmt --check --all
clippy:
strategy:
fail-fast: false
matrix:
include:
- target: x86_64-unknown-linux-gnu
image: ubuntu-latest
- target: x86_64-pc-windows-msvc
image: windows-latest
runs-on: ${{ matrix.image }}
env:
TARGET: ${{ matrix.target }}
steps:
- uses: actions/checkout@v3
- name: Install dependencies for Ubuntu
if: ${{ contains(matrix.image, 'ubuntu') }}
run: sudo apt-get install -y libdbus-1-dev
- uses: Swatinem/rust-cache@v2
- name: Install rust target
run: rustup target add $TARGET
- name: Run clippy
run: cargo clippy --locked --target $TARGET --all -- -D warnings