Merge branch 'jt/doc-post-receive-hook-update'

Doc update.

* jt/doc-post-receive-hook-update:
  doc: clarify post-receive hook behavior
This commit is contained in:
Junio C Hamano
2024-07-31 13:34:16 -07:00

View File

@ -415,13 +415,13 @@ post-receive
This hook is invoked by linkgit:git-receive-pack[1] when it reacts to This hook is invoked by linkgit:git-receive-pack[1] when it reacts to
`git push` and updates reference(s) in its repository. `git push` and updates reference(s) in its repository.
It executes on the remote repository once after all the refs have The hook executes on the remote repository once after all the proposed
been updated. ref updates are processed and if at least one ref is updated as the
result.
This hook executes once for the receive operation. It takes no The hook takes no arguments. It receives one line on standard input for
arguments, but gets the same information as the each ref that is successfully updated following the same format as the
<<pre-receive,'pre-receive'>> <<pre-receive,'pre-receive'>> hook.
hook does on its standard input.
This hook does not affect the outcome of `git receive-pack`, as it This hook does not affect the outcome of `git receive-pack`, as it
is called after the real work is done. is called after the real work is done.
@ -448,6 +448,9 @@ environment variables will not be set. If the client selects
to use push options, but doesn't transmit any, the count variable to use push options, but doesn't transmit any, the count variable
will be set to zero, `GIT_PUSH_OPTION_COUNT=0`. will be set to zero, `GIT_PUSH_OPTION_COUNT=0`.
See the "post-receive" section in linkgit:git-receive-pack[1] for
additional details.
[[post-update]] [[post-update]]
post-update post-update
~~~~~~~~~~~ ~~~~~~~~~~~