From d9ebb7855f1fb5771aaf6c2430778c716e9e03fd Mon Sep 17 00:00:00 2001 From: Emod Kovacs Date: Sat, 30 Dec 2023 01:30:15 +0000 Subject: [PATCH] ci: add clippy --- .github/workflows/test-publish.yml | 23 +++++++++++++++++++++-- Cargo.toml | 2 +- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-publish.yml b/.github/workflows/test-publish.yml index ee57767..2c47220 100644 --- a/.github/workflows/test-publish.yml +++ b/.github/workflows/test-publish.yml @@ -4,13 +4,29 @@ on: branches: - master jobs: + 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 test: + name: Test runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - uses: actions-rs/toolchain@v1 with: - toolchain: stable + toolchain: stable-x86_64-unknown-linux-gnu + profile: minimal override: true - uses: actions-rs/cargo@v1 with: @@ -18,7 +34,10 @@ jobs: all-features: true args: --verbose publish: - needs: test + name: Publish + needs: + - test + - clippy runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 diff --git a/Cargo.toml b/Cargo.toml index 49d319a..cc3164a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -17,4 +17,4 @@ categories = ["web-programming", "http", "middleware"] ntex = "0.7" [dev-dependencies] -ntex = { version = "0.7", features=["tokio"] } +ntex = { version = "0.7", features = ["tokio"] }