Skip to content

Commit

Permalink
ci: use machete to check for unused deps
Browse files Browse the repository at this point in the history
  • Loading branch information
da2ce7 committed Oct 3, 2024
1 parent 1ee60a9 commit 14c26d4
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 4 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/testing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
name: Run Formatting-Checks
run: cargo fmt --check

check:
check:
name: Static Analysis
runs-on: ubuntu-latest
needs: format
Expand All @@ -57,6 +57,12 @@ jobs:
name: Enable Workflow Cache
uses: Swatinem/rust-cache@v2

- id: tools
name: Install Tools
uses: taiki-e/install-action@v2
with:
tool: cargo-machete

- id: check
name: Run Build Checks
run: cargo check --tests --benches --examples --workspace --all-targets --all-features
Expand All @@ -71,7 +77,13 @@ jobs:
RUSTDOCFLAGS: "-D warnings"
run: cargo doc --no-deps --bins --examples --workspace --all-features

- id: clean
name: Clean Build Directory
run: cargo clean

- id: deps
name: Check Unused Dependencies
run: cargo machete

unit:
name: Units
Expand Down Expand Up @@ -134,7 +146,6 @@ jobs:
name: Enable Job Cache
uses: Swatinem/rust-cache@v2


- id: test-sqlite
name: Run Integration Tests (SQLite)
run: ./contrib/dev-tools/container/e2e/sqlite/run-e2e-tests.sh
Expand Down
3 changes: 1 addition & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,10 @@ uuid = { version = "1", features = ["v4"] }

[dev-dependencies]
tempfile = "3"
uuid = { version = "1", features = ["v4"] }
which = "6"

[package.metadata.cargo-machete]
ignored = ["sha-1"]
ignored = ["sha-1", "futures"]

[lints.clippy]
complexity = { level = "deny", priority = -1 }
Expand Down

0 comments on commit 14c26d4

Please sign in to comment.