All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Symonds <dsymonds@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org, Kristis Makris <kristis.makris@asu.edu>,
	David Symonds <dsymonds@gmail.com>
Subject: [PATCH] git-commit: Pass commit SHA-1 hash to post-commit hook.
Date: Wed, 14 Nov 2007 11:29:36 +1100	[thread overview]
Message-ID: <11950001762286-git-send-email-dsymonds@gmail.com> (raw)

Signed-off-by: David Symonds <dsymonds@gmail.com>
---
 Documentation/hooks.txt |    4 ++--
 git-commit.sh           |    2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/Documentation/hooks.txt b/Documentation/hooks.txt
index f110162..d5b18f1 100644
--- a/Documentation/hooks.txt
+++ b/Documentation/hooks.txt
@@ -81,8 +81,8 @@ The default 'commit-msg' hook, when enabled, detects duplicate
 post-commit
 -----------
 
-This hook is invoked by `git-commit`.  It takes no
-parameter, and is invoked after a commit is made.
+This hook is invoked by `git-commit`.  It is passed one
+parameter (the new commit's SHA-1 hash), and is invoked after a commit is made.
 
 This hook is meant primarily for notification, and cannot affect
 the outcome of `git-commit`.
diff --git a/git-commit.sh b/git-commit.sh
index 4853397..fff58cb 100755
--- a/git-commit.sh
+++ b/git-commit.sh
@@ -616,7 +616,7 @@ then
 	git gc --auto
 	if test -x "$GIT_DIR"/hooks/post-commit
 	then
-		"$GIT_DIR"/hooks/post-commit
+		"$GIT_DIR"/hooks/post-commit $commit
 	fi
 	if test -z "$quiet"
 	then
-- 
1.5.3.1

                 reply	other threads:[~2007-11-14  0:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=11950001762286-git-send-email-dsymonds@gmail.com \
    --to=dsymonds@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=kristis.makris@asu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.