mirror of
https://github.com/keycloak/keycloak.git
synced 2026-01-09 23:12:06 -03:30
Only run the pre-commit hooks when Husky is installed (#21587)
This commit is contained in:
parent
57423bca2b
commit
70f293bca1
@ -1,4 +1,14 @@
|
||||
#!/bin/sh
|
||||
. "$(dirname "$0")/_/husky.sh"
|
||||
|
||||
# Get the path the the Husky script.
|
||||
FILE="$(dirname "$0")/_/husky.sh"
|
||||
|
||||
# Exit if Husky is not installed.
|
||||
if [ ! -f "$FILE" ]; then
|
||||
exit 0;
|
||||
fi
|
||||
|
||||
# Run the Husky script, and pre-commit hooks.
|
||||
. $FILE
|
||||
cd js
|
||||
npx lint-staged
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user