diff mbox series

[v2,1/9] fmt-merge-msg: also suppress "into main" by default

Message ID bd2c72a348881bd1e5c5b73545fa0afc866c4ff3.1603461606.git.gitgitgadget@gmail.com (mailing list archive)
State New, archived
Headers show
Series Prepare for changing the default branch name main (last manual part) | expand

Commit Message

Johannes Schindelin Oct. 23, 2020, 1:59 p.m. UTC
From: Johannes Schindelin <johannes.schindelin@gmx.de>

In preparation for changing the default branch name to `main`, let's
skip the suffix "into main" in merge commit messages, the same way that
"into master" has been skipped by default.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
---
 fmt-merge-msg.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/fmt-merge-msg.c b/fmt-merge-msg.c
index bd22e1ea88..9a664a4a58 100644
--- a/fmt-merge-msg.c
+++ b/fmt-merge-msg.c
@@ -626,8 +626,10 @@  int fmt_merge_msg(struct strbuf *in, struct strbuf *out,
 	void *current_branch_to_free;
 	struct merge_parents merge_parents;
 
-	if (!suppress_dest_pattern_seen)
+	if (!suppress_dest_pattern_seen) {
+		string_list_append(&suppress_dest_patterns, "main");
 		string_list_append(&suppress_dest_patterns, "master");
+	}
 
 	memset(&merge_parents, 0, sizeof(merge_parents));