git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git-daemon and hook output

From
Joey Hess <joey@kitenet.net>
Date
Oct 24, 2008, 05:07 UTC
Message-ID
<20081024050713.GA21548@kodama.kitenet.net>

According to githooks, standard output/error for the post-receive and pre-receive hooks will be seen by the user. This is true if using ssh. But if git-daemon has been configured to allow pushes, the user will not see anything these hooks output, and only a not very helpful

 ! [remote rejected] master -> master (pre-receive hook declined)

I suppose that to fix this, git-daemon would have to select on stdout and stderr and pipe them over the wire to the client. Apologies for not even trying to write a patch to do that.

(I ran into this in a real-world application -- I'm implementing anonymous pushes into ikiwiki, which are checked pre-receive to limit them to changes that could be done via the web interface. So all my nice error messages about why a commit is refused are not available, which is a pity.)

-- 
see shy jo
Next: Miklos Vajna
Message 1 of 3 in “git-daemon and hook output”
  1. Joey HessOct 24, 2008
  2. Miklos VajnaOct 24, 2008
  3. Shawn O. PearceOct 24, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.