coreboot-kgpe-d16/util/gitconfig/pre-commit

10 lines
202 B
Bash
Executable File

#!/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