diff --git a/.husky/pre-commit b/.husky/pre-commit index aad24318db4..dee335d9c51 100755 --- a/.husky/pre-commit +++ b/.husky/pre-commit @@ -1,4 +1,8 @@ #!/bin/sh + +# Ignore husky hooks if no frontend code has been changed +git diff --cached --name-only | grep -v --quiet "^pkg/" || exit 0 + . "$(dirname "$0")/_/husky.sh" yarn run precommit