summaryrefslogtreecommitdiff
path: root/git_hooks/pre-commit
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2011-07-29 23:33:48 +0200
committerAndrea Diamantini <adjam7@gmail.com>2011-07-29 23:43:27 +0200
commit7870670d1e3dba21dc4b42352c01b85f72adeea1 (patch)
tree29979912f2628786542287e0190867f327d81628 /git_hooks/pre-commit
parentAdd rekonq commit-template (diff)
downloadrekonq-7870670d1e3dba21dc4b42352c01b85f72adeea1.tar.xz
Copyright year check fixes (waiting for a better regexp...)
Diffstat (limited to 'git_hooks/pre-commit')
-rwxr-xr-xgit_hooks/pre-commit/copyrightyear_check5
1 files changed, 4 insertions, 1 deletions
diff --git a/git_hooks/pre-commit/copyrightyear_check b/git_hooks/pre-commit/copyrightyear_check
index 535b3c16..43c97d0c 100755
--- a/git_hooks/pre-commit/copyrightyear_check
+++ b/git_hooks/pre-commit/copyrightyear_check
@@ -41,7 +41,10 @@ case "${1}" in
echo "Check the files that are being committed for a copyright with a proper year."
;;
* )
- for file in `git diff-index --cached --name-only HEAD | /bin/grep -F .` ; do
+ for file in `git diff-index --cached --name-only HEAD | /bin/grep \.h$` ; do
+ test_file "${file}"
+ done
+ for file in `git diff-index --cached --name-only HEAD | /bin/grep \.cpp$` ; do
test_file "${file}"
done
;;