Skip to content

Commit

Permalink
feat: pr clippy workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
ratankaliani committed Oct 24, 2024
1 parent 84f8731 commit 6f4f3f5
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: PR

on:
push:
branches: [main]
pull_request:
branches:
- "**"
merge_group:

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
lint:
name: Formatting & Clippy
runs-on: [runs-on, runner=16cpu-linux-arm64 , "run-id=${{ github.run_id }}"]
env:
CARGO_NET_GIT_FETCH_WITH_CLI: "true"
steps:
- name: Checkout sources
uses: actions/checkout@v4

- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
components: rustfmt

- name: Run rustfmt
run: cargo fmt --all -- --check
env:
CARGO_INCREMENTAL: 1

- name: Run cargo clippy
run: cargo clippy --all-features --all-targets -- -D warnings -A incomplete-features
env:
CARGO_INCREMENTAL: 1

0 comments on commit 6f4f3f5

Please sign in to comment.