diff --git a/hooks/pre-commit b/hooks/pre-commit index 4dc81e2..c033d45 100755 --- a/hooks/pre-commit +++ b/hooks/pre-commit @@ -93,7 +93,7 @@ for file in $(git diff --name-only --cached); do if [ ${file: -3} == ".rs" ]; then HASH=$(shasum < $file) - NEW_HASH=$(rustfmt --write-mode=display < $file | shasum) + NEW_HASH=$(rustfmt --skip-children --write-mode=display < $file | shasum) echo $HASH echo $NEW_HASH if [ "${HASH}" != "${NEW_HASH}" ]; then