Thread (2 messages) flat view 2 messages, 2 authors, 2019-08-01

Re: Git for Windows v2.23.0-rc0, was Re: [ANNOUNCE] Git v2.23.0-rc0

From: Junio C Hamano <hidden>
Date: 2019-08-01 21:55:07
Subsystem: the rest · Maintainer: Linus Torvalds

Possibly related (same subject, not in this thread)

Junio C Hamano [off-list ref] writes:
Jeff King [off-list ref] writes:
quoted
quoted
+	if (mailmap < 0)
 		mailmap = 0;
-	}
This should be "mailmap = 1" to match the commit message, no? (Which
also implies we may want a new test).
Gaa, of course.
-- >8 --
From: Junio C Hamano <redacted>
Date: Thu, 1 Aug 2019 14:48:34 -0700
Subject: [PATCH] log: really flip the --mailmap default

Signed-off-by: Junio C Hamano <redacted>
---
 builtin/log.c      | 2 +-
 t/t4203-mailmap.sh | 5 +++++
 2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/builtin/log.c b/builtin/log.c
index 40b4cbf57d..02fa179077 100644
--- a/builtin/log.c
+++ b/builtin/log.c
@@ -205,7 +205,7 @@ static void cmd_log_init_finish(int argc, const char **argv, const char *prefix,
 	userformat_find_requirements(NULL, &w);
 
 	if (mailmap < 0)
-		mailmap = 0;
+		mailmap = 1;
 
 	if (!rev->show_notes_given && (!rev->pretty_given || w.notes))
 		rev->show_notes = 1;
diff --git a/t/t4203-mailmap.sh b/t/t4203-mailmap.sh
index 43b1522ea2..ede0c292af 100755
--- a/t/t4203-mailmap.sh
+++ b/t/t4203-mailmap.sh
@@ -461,6 +461,11 @@ test_expect_success 'Grep author with log.mailmap' '
 	test_cmp expect actual
 '
 
+test_expect_success 'log.mailmap is true by default these days' '
+	git log --author Santa | grep Author >actual &&
+	test_cmp expect actual
+'
+
 test_expect_success 'Only grep replaced author with --use-mailmap' '
 	git log --use-mailmap --author "<cto@coompany.xx>" >actual &&
 	test_must_be_empty actual
-- 
2.23.0-rc0-155-g5fbf3435fe
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help