aboutsummaryrefslogtreecommitdiff
path: root/util/gitconfig/pre-commit
blob: 257f6964bb8b135fa810c96aea6523d010211981 (plain)
1
2
3
4
5
6
7
8
9
#!/bin/sh
%MAKE% lint-stable

PATCHDIFF=$(git diff --cached)
if echo "$PATCHDIFF" | grep -q "@@"; then
	echo
	echo "Running checkpatch"
	echo "$PATCHDIFF" | util/lint/checkpatch.pl --no-signoff -q -
fi