Skip to content

Commit 856850b

Browse files
daanrijpkemacbDaanRijpkema
authored andcommitted
Add linting step to pre-commit hook
Enhance the pre-commit hook to include a linting step after running unit tests for PHP files. This ensures code quality and adherence to coding standards before commits are finalized.
1 parent 3775b2b commit 856850b

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

.githooks/pre-commit

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ set -eu
44
if git diff --cached --name-only --diff-filter=ACM | grep -qE '\.php$'; then
55
echo "PHP files changed — running unit tests..."
66
make test_unit
7+
8+
make lint
79
else
810
echo "No PHP changes — skipping unit tests."
911
fi

0 commit comments

Comments
 (0)