{"thread":{"id":"16032","subject":"git-daemon and hook output","startedAt":"2008-10-24T05:07:13Z","lastAt":"2008-10-24T20:42:44Z","messageCount":3,"participants":["Joey Hess","Miklos Vajna","Shawn O. Pearce"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"93825","messageId":"20081024050713.GA21548@kodama.kitenet.net","threadId":"16032","inReplyTo":null,"subject":"git-daemon and hook output","fromName":"Joey Hess","fromEmail":"joey@kitenet.net","sentAt":"2008-10-24T05:07:13Z","receivedAt":"2008-10-24T05:07:13Z","isPatch":false,"sender":{"key":"joey@kitenet.net","avatar":"https://avatars.githubusercontent.com/u/16392?v=4"},"body":"According to githooks, standard output/error for the post-receive and\npre-receive hooks will be seen by the user. This is true if using ssh.\nBut if git-daemon has been configured to allow pushes, the user will\nnot see anything these hooks output, and only a not very helpful\n\n ! [remote rejected] master -> master (pre-receive hook declined)\n\nI suppose that to fix this, git-daemon would have to select on stdout\nand stderr and pipe them over the wire to the client. Apologies for not\neven trying to write a patch to do that.\n\n(I ran into this in a real-world application -- I'm implementing\nanonymous pushes into ikiwiki, which are checked pre-receive to limit\nthem to changes that could be done via the web interface. So all my nice\nerror messages about why a commit is refused are not available, which is\na pity.)\n\n-- \nsee shy jo\n"},{"id":"93881","messageId":"20081024203943.GV26961@genesis.frugalware.org","threadId":"16032","inReplyTo":"20081024050713.GA21548@kodama.kitenet.net","subject":"Re: git-daemon and hook output","fromName":"Miklos Vajna","fromEmail":"vmiklos@frugalware.org","sentAt":"2008-10-24T20:39:43Z","receivedAt":"2008-10-24T20:39:43Z","isPatch":false,"sender":{"key":"vmiklos@frugalware.org","avatar":"https://gravatar.com/avatar/401c1cbbb3a5d13e650c691a2c71d6fd0b80df1a01bc74d9f1972675dd58f2bd?d=mp&s=160"},"body":"On Fri, Oct 24, 2008 at 01:07:13AM -0400, Joey Hess <joey@kitenet.net> wrote:\n> I ran into this in a real-world application -- I'm implementing\n> anonymous pushes into ikiwiki, which are checked pre-receive to limit\n> them to changes that could be done via the web interface. So all my nice\n> error messages about why a commit is refused are not available, which is\n> a pity.\n\nI think the recommended protocol even for anonymous push is ssh, at\nleast that's what repo.or.cz uses for the 'mob' user, which is\nequivalent to anonymous, AFAIK.\n\n(The source is available under repo.git, I did not have a look how one\ncan set up an account - using git-shell - that can be used without a\npassword.)\n"},{"id":"93882","messageId":"20081024204243.GE14786@spearce.org","threadId":"16032","inReplyTo":"20081024203943.GV26961@genesis.frugalware.org","subject":"Re: git-daemon and hook output","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2008-10-24T20:42:44Z","receivedAt":"2008-10-24T20:42:44Z","isPatch":false,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Miklos Vajna <vmiklos@frugalware.org> wrote:\n> On Fri, Oct 24, 2008 at 01:07:13AM -0400, Joey Hess <joey@kitenet.net> wrote:\n> > I ran into this in a real-world application -- I'm implementing\n> > anonymous pushes into ikiwiki, which are checked pre-receive to limit\n> > them to changes that could be done via the web interface. So all my nice\n> > error messages about why a commit is refused are not available, which is\n> > a pity.\n> \n> I think the recommended protocol even for anonymous push is ssh, at\n> least that's what repo.or.cz uses for the 'mob' user, which is\n> equivalent to anonymous, AFAIK.\n\nNah.  git:// supports anonymous push.  For some applications its\njust what people want.  I say the original change is worthwhile;\nexpose the remote address and let a hook do logging and/or denials\nbased on its own logic.\n\n-- \nShawn.\n"}]}