Skip to content

Commit

Permalink
Added pipeline to run cargo check, fmt and clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
s-simoncelli committed Aug 4, 2024
1 parent 6733f83 commit 2cdef34
Showing 1 changed file with 55 additions and 0 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/check-and-lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
on:
pull_request:
push:
branches:
- main


name: Check and Lint

jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- uses: actions-rs/cargo@v1
with:
command: check

fmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- run: rustup component add rustfmt
- uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check

clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
components: clippy
override: true
- uses: actions-rs/clippy-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
args: --all-features
name: Clippy Output

0 comments on commit 2cdef34

Please sign in to comment.