This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: glibc.git: hook to prohibit pushing "bad-merge" commits
- From: Petr Baudis <pasky at suse dot cz>
- To: Jim Meyering <jim at meyering dot net>, Andreas Schwab <schwab at linux-m68k dot org>
- Cc: "GNU C. Library" <libc-alpha at sourceware dot org>
- Date: Tue, 30 Nov 2010 03:42:03 +0100
- Subject: Re: glibc.git: hook to prohibit pushing "bad-merge" commits
Hi!
On Mon, Nov 29, 2010 at 10:07:44PM +0100, Jim Meyering wrote:
> I've temporarily done this on the server,
>
> GIT_DIR=/git/glibc.git git config --bool hooks.allowbadwhitespace true
>
> so you should be able to push.
> Let me know when you're done and I'll reset it.
Thanks, you can reset it now.
> I'm not sure if this is exactly the script in glibc's repository,
> but it's close. If you're interested, I can make it so you can use the
> mechanism described in comments to flip this flag yourself:
>
> http://git.et.redhat.com/?p=ovirt-server.git;a=blob_plain;f=git-hook/update;hb=refs/heads/vcs-admin
Good to know this is (similar to) the code of the hook!
It would be quite nice to have a way for committers to tweak this knob
if they are sure they need it.
I wonder if there's much value in the strict checking of hooks policy
and fast-forwarding (which is a bit annoying e.g. in case of the pasky/*
branches) anyway, but I do not feel strongly about it as long as both
can be worked around (the latter can be by first removing, then
re-pushing the branch).
On Mon, Nov 29, 2010 at 10:28:04PM +0100, Andreas Schwab wrote:
> Petr Baudis <pasky@suse.cz> writes:
>
> > I added .gitattributes entry INSTALL -whitespace in the same commit,
>
> You'll probably need to push that separately.
Ah, interesting idea! That might have helped. So far, it seems to me
that git diff --check actually ought to ignore in-tree .gitattributes
when running in a bare repository, but I'm surely missing something
since I assume it has been already tested on the timezone/ case?
--
Petr "Pasky" Baudis
The true meaning of life is to plant a tree under whose shade
you will never sit.