From 76039fadd934a9f0798fee160877a4247c71c352 Mon Sep 17 00:00:00 2001 From: Piotr Findeisen Date: Thu, 25 Jul 2024 01:30:55 +0200 Subject: [PATCH] Unify CI and pre-commit hook settings for clippy (#11640) pre-commit hook runs clippy and CI scripts run clippy too. The commands are and should be the same. Let's define them once. --- pre-commit.sh | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/pre-commit.sh b/pre-commit.sh index 09cf431a1409..c81dd9f8e5e8 100755 --- a/pre-commit.sh +++ b/pre-commit.sh @@ -57,13 +57,7 @@ fi # 1. cargo clippy echo -e "$(GREEN INFO): cargo clippy ..." - -# Cargo clippy always return exit code 0, and `tee` doesn't work. -# So let's just run cargo clippy. -cargo clippy --all-targets --workspace --features avro,pyarrow -- -D warnings -pushd datafusion-cli -cargo clippy --all-targets --all-features -- -D warnings -popd +./ci/scripts/rust_clippy.sh echo -e "$(GREEN INFO): cargo clippy done" # 2. cargo fmt: format with nightly and stable.