git/list[1] front-page[2] threads[3] people[4] search[5] about
 

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

From
Junio C Hamano <gitster@pobox.com>
Date
Jan 18, 2010, 03:34 UTC
Message-ID
<7vfx64uluo.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20100118014735.GA6831@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 13 quoted lines
> 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.

Previous: Jeff King
Message 6 of 6 in “commit: match explicit-ident semantics for summary and template”
  1. commit: match explicit-ident semantics for summary and templateJeff King, Jan 17, 2010
  2. Johannes SixtJan 17, 2010
  3. Jeff KingJan 17, 2010
  4. Junio C HamanoJan 17, 2010
  5. Jeff KingJan 18, 2010
  6. Junio C HamanoJan 18, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.