Files
AndroidJetpack/Fragula/pre-commit
T
coco 723ce1af5c a
2026-07-03 15:12:48 +08:00

15 lines
202 B
Bash

#!/bin/bash
git stash -q --keep-index
echo "Running git pre-commit hook"
./gradlew ktlint
RESULT=$?
git stash pop -q
# return 1 exit code if running checks fails
[ $RESULT -ne 0 ] && exit 1
exit 0