Skip to content

Commit 6b34b13

Browse files
ci: enforce strict Clippy lints by denying warnings
1 parent ef27a0a commit 6b34b13

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ jobs:
8989
- name: Rustfmt
9090
run: just backend lint-rustfmt
9191
- name: Clippy
92-
run: just backend lint-clippy
92+
run: just backend lint-clippy --deny-warnings
9393
- name: SQLFluff
9494
run: just backend lint-sql
9595

geoengine/justfile

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,11 @@ generate-openapi-spec: common::_clear
2121
lint: common::_clear lint-rustfmt lint-clippy lint-sql
2222

2323
# Run clippy for all features and all targets.
24-
[arg('fix', long='fix', value='--fix', help='Automatically apply fixes where possible.')]
24+
[arg('fix', long='fix', value='--fix --allow-dirty', help='Automatically apply fixes where possible.')]
25+
[arg('deny-warnings', long='deny-warnings', value='-D warnings', help='Deny warnings.')]
2526
[group("lint")]
26-
lint-clippy fix="": common::_clear
27-
cargo clippy --all-features --all-targets {{ if fix == "--fix" { "--fix --allow-dirty" } else { "" } }}
27+
lint-clippy fix="" deny-warnings="": common::_clear
28+
cargo clippy --all-features --all-targets {{ fix }} -- {{ deny-warnings }}
2829

2930
# Run rustfmt
3031
[arg('write', long='write', value='--write', help='Write changes to files instead of checking.')]

0 commit comments

Comments
 (0)