* GIT_PUSH_CERT* env vars and update/post-update hooks...
@ 2014-12-24 1:57 Sitaram Chamarty
2014-12-29 16:36 ` Junio C Hamano
0 siblings, 1 reply; 2+ messages in thread
From: Sitaram Chamarty @ 2014-12-24 1:57 UTC (permalink / raw)
To: git@vger.kernel.org
Hi git core devs,
Any chance I could persuade you to set the GIT_PUSH_CERT* environment
variables for the update (and post-update) hooks also?
Background: gitolite "takes over" the update hook [1] for authorisation
and enforcement, and I want to avoid taking over the pre-receive hook
also in order to do this check.
The post-update is not so important; gitolite doesn't use it anyway, so
if I have to take over one of them, I may as well take over
post-receive. I just added that for consistency.
thanks
sitaram
[1]: because it's nice to *selectively* reject refs when more than one
ref is pushed at the same time; pre-receive is "all or none".
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: GIT_PUSH_CERT* env vars and update/post-update hooks...
2014-12-24 1:57 GIT_PUSH_CERT* env vars and update/post-update hooks Sitaram Chamarty
@ 2014-12-29 16:36 ` Junio C Hamano
0 siblings, 0 replies; 2+ messages in thread
From: Junio C Hamano @ 2014-12-29 16:36 UTC (permalink / raw)
To: Sitaram Chamarty; +Cc: git@vger.kernel.org
Sitaram Chamarty <sitaramc@gmail.com> writes:
> Any chance I could persuade you to set the GIT_PUSH_CERT* environment
> variables for the update (and post-update) hooks also?
I do not think of a fundamental reason why we shouldn't give these
environment variables to update or other hooks. It should just be
the matter of calling prepare_push_cert_sha1() on the child_process
struct used to run the hooks you want.
> [1]: because it's nice to *selectively* reject refs when more than one
> ref is pushed at the same time; pre-receive is "all or none".
It cuts both ways; inside "update", your "selective" rejection
cannot make the decision with the whole picture (you only have a
peephole into individual changes). "post-receive" sees the whole
picture, but it has to say all-or-none. Neither is ideal if you
truly want a useful "selective".
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-12-29 16:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-24 1:57 GIT_PUSH_CERT* env vars and update/post-update hooks Sitaram Chamarty
2014-12-29 16:36 ` Junio C Hamano
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).