#!/bin/sh
%MAKE% lint-stable
PATCHDIFF=$(git diff --cached)
if printf "%s\n" "$PATCHDIFF" | grep -q "@@"; then
echo
echo "Running checkpatch"
printf "%s\n" "$PATCHDIFF" | util/lint/checkpatch.pl --no-signoff -q -
fi