Re: [PATCH] commit: match explicit-ident semantics for summary and template

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jeff King <peff@xxxxxxxx> writes:

> On Sun, Jan 17, 2010 at 02:03:48PM -0800, Junio C Hamano wrote:
>
>> We could say something like
>> 
>> 	if (!(user_ident_explicitly_given & IDENT_EMAIL_GIVEN))
>> 
>> and it probably is a safer change on platforms with GECOS available, but
>> then wouldn't msysgit folks have to fork this code?
>
> I hadn't thought to be specific to "email must be given". That is, I had
> assumed if you gave a name but not email, you would also be considered
> competent enough to avoid the warning. But I really can't see anybody
> doing that, so the semantics you suggest above are fine by me.

It is fine if we keep insisting on getting both explicitly, but as you
said, I think if we have an explicit user.email, it is much more likely
that the user are happy with what we get from the GECOS than the user is
unhappy with GECOS but hasn't learnt user.name configuration.

Also if you have neither user.name nor user.email on your fresh box, the
chance that GECOS gives us the name you desire is much much more likely
than the chance the output from `whoami`@`hostname -f` happens to match
your desired e-mail identity.  I think checking MAIL only would probably
be the best heuristics.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]