diff options
-rwxr-xr-x | tools/pre-commit | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/pre-commit b/tools/pre-commit index 4fc5352d34..2103d3482f 100755 --- a/tools/pre-commit +++ b/tools/pre-commit @@ -7,7 +7,7 @@ # From # http://mark-story.com/posts/view/using-git-commit-hooks-to-prevent-stupid-mistakes # -for FILE in `git diff-index --cached --name-only HEAD` ; do +for FILE in `git diff-index --cached --name-only HEAD | grep "\.[ch]$"` ; do #Exit immediately if a command exits with a non-zero status. set -e |