* [PATCH] config --global --edit: generate correct .gitconfig template
@ 2015-05-06 17:41 Pete Harlan
2015-05-06 17:56 ` Junio C Hamano
2015-05-07 8:45 ` Matthieu Moy
0 siblings, 2 replies; 5+ messages in thread
From: Pete Harlan @ 2015-05-06 17:41 UTC (permalink / raw)
To: git, Matthieu.Moy; +Cc: Pete Harlan
When the user asks to edit an empty .gitconfig file, we learned to
generate a default version in 9830534e (config --global --edit: create
a template file if needed, 2014-07-25), but the generated config
mistakenly set core.user and core.email instead of user.name and
user.email. Fix this.
Signed-off-by: Pete Harlan <pchpublic88@gmail.com>
---
I ran up against this yesterday and it is easy enough to fix, but I
don't have time right now to write tests for it.
builtin/config.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/builtin/config.c b/builtin/config.c
index d32c532..bfd3016 100644
--- a/builtin/config.c
+++ b/builtin/config.c
@@ -455,9 +455,9 @@ static char *default_user_config(void)
struct strbuf buf = STRBUF_INIT;
strbuf_addf(&buf,
_("# This is Git's per-user configuration file.\n"
- "[core]\n"
+ "[user]\n"
"# Please adapt and uncomment the following lines:\n"
- "# user = %s\n"
+ "# name = %s\n"
"# email = %s\n"),
ident_default_name(),
ident_default_email());
--
2.4.0.rc3
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] config --global --edit: generate correct .gitconfig template
2015-05-06 17:41 [PATCH] config --global --edit: generate correct .gitconfig template Pete Harlan
@ 2015-05-06 17:56 ` Junio C Hamano
2015-05-06 18:10 ` Pete Harlan
2015-05-07 8:45 ` Matthieu Moy
1 sibling, 1 reply; 5+ messages in thread
From: Junio C Hamano @ 2015-05-06 17:56 UTC (permalink / raw)
To: Pete Harlan; +Cc: git, Matthieu.Moy
Pete Harlan <pchpublic88@gmail.com> writes:
> When the user asks to edit an empty .gitconfig file, we learned to
> generate a default version in 9830534e (config --global --edit: create
> a template file if needed, 2014-07-25), but the generated config
> mistakenly set core.user and core.email instead of user.name and
> user.email. Fix this.
>
> Signed-off-by: Pete Harlan <pchpublic88@gmail.com>
> ---
Thanks, I think this was already done in 7e110524 (config: fix
settings in default_user_config template, 2015-04-17).
>
> I ran up against this yesterday and it is easy enough to fix, but I
> don't have time right now to write tests for it.
>
> builtin/config.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/builtin/config.c b/builtin/config.c
> index d32c532..bfd3016 100644
> --- a/builtin/config.c
> +++ b/builtin/config.c
> @@ -455,9 +455,9 @@ static char *default_user_config(void)
> struct strbuf buf = STRBUF_INIT;
> strbuf_addf(&buf,
> _("# This is Git's per-user configuration file.\n"
> - "[core]\n"
> + "[user]\n"
> "# Please adapt and uncomment the following lines:\n"
> - "# user = %s\n"
> + "# name = %s\n"
> "# email = %s\n"),
> ident_default_name(),
> ident_default_email());
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] config --global --edit: generate correct .gitconfig template
2015-05-06 17:56 ` Junio C Hamano
@ 2015-05-06 18:10 ` Pete Harlan
2015-05-07 18:41 ` Junio C Hamano
0 siblings, 1 reply; 5+ messages in thread
From: Pete Harlan @ 2015-05-06 18:10 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git, Matthieu.Moy
On Wed, May 6, 2015 at 10:56 AM, Junio C Hamano <gitster@pobox.com> wrote:
> Thanks, I think this was already done in 7e110524 (config: fix
> settings in default_user_config template, 2015-04-17).
Whoops......indeed, I'll check more than just master next time, thanks.
--Pete
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] config --global --edit: generate correct .gitconfig template
2015-05-06 17:41 [PATCH] config --global --edit: generate correct .gitconfig template Pete Harlan
2015-05-06 17:56 ` Junio C Hamano
@ 2015-05-07 8:45 ` Matthieu Moy
1 sibling, 0 replies; 5+ messages in thread
From: Matthieu Moy @ 2015-05-07 8:45 UTC (permalink / raw)
To: Pete Harlan; +Cc: git
Pete Harlan <pchpublic88@gmail.com> writes:
> When the user asks to edit an empty .gitconfig file, we learned to
> generate a default version in 9830534e (config --global --edit: create
> a template file if needed, 2014-07-25), but the generated config
> mistakenly set core.user and core.email instead of user.name and
> user.email.
Oops, indeed. I don't know how I could came up with such mistake and not
notice.
--
Matthieu Moy
http://www-verimag.imag.fr/~moy/
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] config --global --edit: generate correct .gitconfig template
2015-05-06 18:10 ` Pete Harlan
@ 2015-05-07 18:41 ` Junio C Hamano
0 siblings, 0 replies; 5+ messages in thread
From: Junio C Hamano @ 2015-05-07 18:41 UTC (permalink / raw)
To: Pete Harlan; +Cc: git, Matthieu.Moy
Pete Harlan <pchpublic88@gmail.com> writes:
> On Wed, May 6, 2015 at 10:56 AM, Junio C Hamano <gitster@pobox.com> wrote:
>> Thanks, I think this was already done in 7e110524 (config: fix
>> settings in default_user_config template, 2015-04-17).
>
> Whoops......indeed, I'll check more than just master next time, thanks.
Building 'next' and using it for your everyday Git need is a good
thing to do. You'll get well-eyeballed fixes earlier that way.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2015-05-07 18:41 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-06 17:41 [PATCH] config --global --edit: generate correct .gitconfig template Pete Harlan
2015-05-06 17:56 ` Junio C Hamano
2015-05-06 18:10 ` Pete Harlan
2015-05-07 18:41 ` Junio C Hamano
2015-05-07 8:45 ` Matthieu Moy
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.