Skip to content

Commit

Permalink
+ clippy workflow ci
Browse files Browse the repository at this point in the history
  • Loading branch information
oluceps committed Nov 10, 2024
1 parent 35780b5 commit 0569dee
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/clippy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
on: push
name: Clippy check

# Make sure CI fails on all warnings, including Clippy lints
env:
RUSTFLAGS: "-Dwarnings"

jobs:
clippy_check:
runs-on: ubuntu-latest
permissions:
id-token: "write"
contents: "read"
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@main
- uses: DeterminateSystems/magic-nix-cache-action@main
- name: Run cargo clippy
run: |
nix develop -c cargo check
2 changes: 2 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,8 @@
pkgs.vaultix
];

env.RUSTFLAGS = "-Dwarnings";

# see https://discourse.nixos.org/t/rust-src-not-found-and-other-misadventures-of-developing-rust-on-nixos/11570/12
RUST_SRC_PATH = "${
pkgs.rust-bin.nightly.latest.default.override {
Expand Down

0 comments on commit 0569dee

Please sign in to comment.