Skip to content

Commit

Permalink
Pre-push script invoking Clippy linter
Browse files Browse the repository at this point in the history
  • Loading branch information
khssnv committed Sep 25, 2023
1 parent c34d57b commit 11dba86
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions scripts/pre-push.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/sh

# Check code with clippy before publishing
cargo clippy --all --all-targets -- -D warnings
if [ $? -ne 0 ]; then
echo "Run \`cargo clippy --fix --all --allow-staged --allow-dirty\` to apply clippy's suggestions."
exit 1
fi

0 comments on commit 11dba86

Please sign in to comment.