@matheusbsbs / matheus-bagliano / commits / c646217e13
Fork 0

pre-commit.sample: don't print incidental SHA1

Make the sample pre-commit hook script discard all git-rev-parse output, not just stderr. Otherwise, it would print an SHA1. Signed-off-by: Jim Meyering <meyering@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jim Meyering committed May 16, 2009 at 12:21 UTC c646217e1366b0397552fad8c32acb47fbe8977d
1 file changed +1 -1
templates/hooks--pre-commit.sample
+1 -1
@@ -7,7 +7,7 @@
7 #
8 # To enable this hook, rename this file to "pre-commit".
9
10 -if git-rev-parse --verify HEAD 2>/dev/null
10 +if git-rev-parse --verify HEAD >/dev/null 2>&1
11 then
12 against=HEAD
13 else