]> git.ipfire.org Git - thirdparty/git.git/commit
doc: clarify post-receive hook behavior
authorJustin Tobler <jltobler@gmail.com>
Mon, 15 Jul 2024 18:37:39 +0000 (13:37 -0500)
committerJunio C Hamano <gitster@pobox.com>
Mon, 15 Jul 2024 18:43:38 +0000 (11:43 -0700)
commit8db8786fc2de36731738fd480d1df422c6e86579
treee1e29d75de33c03842987f9d655832eacedc7bf3
parent337b4d400023d22207bcc3c29e9ebab31bf96fc2
doc: clarify post-receive hook behavior

The `githooks` documentation mentions that the post-receive hook
executes once after git-receive-pack(1) updates all references and that
it also receives the same information as the pre-receive hook on
standard input. This is misleading though because the hook only
executes once if at least one of the attempted reference updates is
successful. Also, while each line provided on standard input is in the
same format as the pre-receive hook, the information received only
includes the set of references that were successfully updated.

Update the documentation to clarify these points and also provide a
reference to the post-receive hook section of the `git-receive-pack`
documentation which has additional information.

Signed-off-by: Justin Tobler <jltobler@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Documentation/githooks.txt