Skip to content

Commit

Permalink
Documentation: stdout of update-hook is connected to /dev/null
Browse files Browse the repository at this point in the history
Mention that update-hook does not emit its stdout to the sender.

Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
Junio C Hamano committed Dec 20, 2005
1 parent ef1cc2c commit 3aadad1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
8 changes: 8 additions & 0 deletions Documentation/hooks.txt
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,10 @@ Another use suggested on the mailing list is to use this hook to
implement access control which is finer grained than the one
based on filesystem group.

The standard output of this hook is sent to /dev/null; if you
want to report something to the git-send-pack on the other end,
you can redirect your output to your stderr.

post-update
-----------

Expand All @@ -125,3 +129,7 @@ the outcome of `git-receive-pack`.
The default post-update hook, when enabled, runs
`git-update-server-info` to keep the information used by dumb
transport up-to-date.

The standard output of this hook is sent to /dev/null; if you
want to report something to the git-send-pack on the other end,
you can redirect your output to your stderr.
8 changes: 6 additions & 2 deletions Documentation/howto/rebuild-from-update-hook.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ The pages under http://www.kernel.org/pub/software/scm/git/docs/
are built from Documentation/ directory of the git.git project
and needed to be kept up-to-date. The www.kernel.org/ servers
are mirrored and I was told that the origin of the mirror is on
the machine master.kernel.org, on which I was given an account
the machine $some.kernel.org, on which I was given an account
when I took over git maintainership from Linus.

The directories relevant to this how-to are these two:
Expand Down Expand Up @@ -63,7 +63,7 @@ like this:
EOF
$ chmod +x /pub/scm/git/git.git/hooks/post-update

There are three things worth mentioning:
There are four things worth mentioning:

- The update-hook is run after the repository accepts a "git
push", under my user privilege. It is given the full names
Expand All @@ -77,6 +77,10 @@ There are three things worth mentioning:
pull" it does into $HOME/doc-git/docgen/ repository would not
work correctly.

- The stdout of update hook script is not connected to git
push; I run the heavy part of the command inside "at", to
receive the execution report via e-mail.

- This is still crude and does not protect against simultaneous
make invocations stomping on each other. I would need to add
some locking mechanism for this.
Expand Down

0 comments on commit 3aadad1

Please sign in to comment.