diff-merges: add '--diff-merges=1' as synonym for 'first-parent'
As we now have --diff-merges={m|c|cc}, add --diff-merges=1 as synonym for --diff-merges=first-parent, to have shorter mnemonics for it as well. Signed-off-by: Sergey Organov <sorganov@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Sergey Organov committed
Dec 21, 2020 at 18:19 UTC
388091fe4d9e06475f491c195e84e1996aad3f42
1 file changed
+1
-1
diff-merges.c
+1
-1
@@ -58,7 +58,7 @@ static void set_diff_merges(struct rev_info *revs, const char *optarg)
58
return;
59
}
60
61
- if (!strcmp(optarg, "first-parent"))
61
+ if (!strcmp(optarg, "1") || !strcmp(optarg, "first-parent"))
62
set_first_parent(revs);
63
else if (!strcmp(optarg, "m") || !strcmp(optarg, "separate"))
64
set_separate(revs);