Add cargo fmt to pre-commit githook

To save devs getting frustrated by CI; add a call to `cargo +nightly
fmt` to our git pre-commit hook.
This commit is contained in:
Tobin C. Harding 2022-11-22 08:59:09 +11:00
parent 0516ddeb8d
commit 75f3886812
1 changed files with 3 additions and 0 deletions

View File

@ -48,3 +48,6 @@ git diff-index --check --cached $against -- || exit 1
# Check that code lints cleanly.
cargo clippy --features=rand-std,recovery,lowmemory,global-context --all-targets -- -D warnings || exit 1
# Check that there are no formatting issues.
cargo +nightly fmt --check || exit 1