Skip to content

Commit

Permalink
add linting action
Browse files Browse the repository at this point in the history
  • Loading branch information
tibvdm committed Apr 3, 2024
1 parent a5301dc commit 9c2d43d
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
on: [ push, pull_request ]

name: Lint

jobs:
lint:
name: Clippy + rustfmt
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install minimal nightly toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
components: rustfmt, clippy
override: true

- name: Run cargo check
uses: actions-rs/cargo@v1
with:
command: check

- name: Run cargo fmt
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check

- name: Run cargo clippy
uses: actions-rs/cargo@v1
with:
command: clippy
args: -- -D warnings


0 comments on commit 9c2d43d

Please sign in to comment.