Subject: [bug#66618] [PATCH] etc: gitconfig: Remove the default email address to avoid mistakes.

From: Clément Lassieur <[email-masked]>
Date: Sun, 22 Oct 2023 22:55:12 +0200

Maxim Cournoyer <[email-masked]> writes:

> Hi Simon,
>
> Simon Tournier <[email-masked]> writes:
>
>> Hi Maxim,
>>
>> On Thu, 19 Oct 2023 at 21:54, Maxim Cournoyer <[email-masked]> wrote:
>>
>>> One could argue it's also a misleading documentation.  It should say if
>>> a 'to' address is not specified *or* configured.  
>>
>> Well, personally I prefer: « Explicit is better than implicit. » and
>> « Errors should never pass silently.  Unless explicitly silenced. ».
>>
>> Here, the default
>>
>>      [sendemail]
>>             to = [email-masked]
>>
>> makes something implicit – which is not necessary bad – but it hides
>> potential errors – which is not good.
>
> But that's true for any automation of git.  If we follow that logic we
> can remove the other git configurations because they may be surprising,
> and the send-email hook that notifies people, because that can again be
> surprising.

Some automation is fine (although maybe not necessary) because it's
about things we want to enforce (like signed commits).

> Obviously, I'd rather not go that slope.  The small cost in surprise is
> offset by removing manual work for myself and I'd expect/hope other
> committers.  Does that make sense?

I don't think there is a need for `--to` automation in Guix repo because
it's something the user can automate in their own ~/.gitconfig (with
`includeIf`[0]).

[0]: https://git-scm.com/docs/git-config#_conditional_includes

Clément