develooper Front page | perl.perl5.porters | Postings from March 2013

Re: git-hook to prevent perlbug as patch author

From:
Steffen Mueller
Date:
March 14, 2013 14:46
Subject:
Re: git-hook to prevent perlbug as patch author
Message ID:
5141E2C5.9030800@cpan.org
On 03/11/2013 11:55 PM, Tony Cook wrote:
> On Thu, Feb 28, 2013 at 12:20:25AM +1100, Tony Cook wrote:
>> On Wed, Jan 30, 2013 at 07:38:29AM +0100, Steffen Mueller wrote:
>>> I will bribe Dennis into installing such post-receive a hook if
>>> somebody provides it.
>>
>> An update hook as discussed is attached, with only the following
>> change:
>>
>> --- update.orig 2013-01-28 11:04:13.000000000 +0100
>> +++ update      2013-02-27 13:22:35.000000000 +0100
>> @@ -78,6 +78,13 @@
>>                  ;;
>>          refs/heads/*,commit)
>>                  # branch
>> +               authoremail=`git log --format=%ae -n1 "$newrev"`
>> +               if [ "$refname" = refs/heads/blead ] &&
>> +                    ( git config --get-all blacklist.email | grep -qx "$authoremail" ) ;
>> +                   then
>> +                   echo "*** $authoremail cannot author new commits in blead" >&2
>> +                   exit 1
>> +               fi
>>                  ;;
>>          refs/heads/*,delete)
>>                  # delete branch
>>
>> The blacklisted emails can be configured with git config:
>>
>>    cd perl.git
>>    git config --add blacklist.email foo@example.com
>
> Should I install this?

I think yes. Sorry for dropping the ball on it.

--Steffen




nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About