Skip to content

Commit

Permalink
Add clippy-test.yml
Browse files Browse the repository at this point in the history
Check for code quality improvements on all rust source code with
`clippy` in the `test` workspace.
  • Loading branch information
MarkusPettersson98 committed Dec 8, 2023
1 parent 1ba7b47 commit 5dacdec
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/clippy-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Run `clippy` on the `test` workspace
---
name: Rust - Run Clippy to check lints (test workspace)
on:
pull_request:
paths:
- 'test/**/*.rs'
workflow_dispatch:
jobs:
clippy-check:
name: Clippy linting
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Install Protoc
uses: arduino/setup-protoc@v1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}

- uses: actions-rs/[email protected]
with:
toolchain: stable
components: clippy
override: true

- name: Install build dependencies
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-get update
sudo apt-get install libdbus-1-dev
- name: Clippy check
working-directory: test
shell: bash
env:
RUSTFLAGS: --deny warnings
run: |
time cargo clippy --locked -- -W clippy::unused_async

0 comments on commit 5dacdec

Please sign in to comment.