status: suggest 'git merge --abort' when appropriate

We already suggest 'git rebase --abort' during a conflicted rebase. Similarly, suggest 'git merge --abort' during conflict resolution on 'git merge'. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Matthieu Moy committed Jul 21, 2016 at 14:58 UTC b0a61ab23c0fd51a1b641b481e6a63f8661a8f9f
3 files changed +10 -2
t/t7060-wtstatus.sh
+4
@@ -34,6 +34,7 @@ test_expect_success 'M/D conflict does not segfault' '
34 On branch side
35 You have unmerged paths.
36 (fix conflicts and run "git commit")
37 + (use "git merge --abort" to abort the merge)
38
39 Unmerged paths:
40 (use "git add/rm <file>..." as appropriate to mark resolution)
@@ -138,6 +139,7 @@ test_expect_success 'status when conflicts with add and rm advice (deleted by th
139 On branch master
140 You have unmerged paths.
141 (fix conflicts and run "git commit")
142 + (use "git merge --abort" to abort the merge)
143
144 Unmerged paths:
145 (use "git add/rm <file>..." as appropriate to mark resolution)
@@ -171,6 +173,7 @@ test_expect_success 'status when conflicts with add and rm advice (both deleted)
173 On branch conflict_second
174 You have unmerged paths.
175 (fix conflicts and run "git commit")
176 + (use "git merge --abort" to abort the merge)
177
178 Unmerged paths:
179 (use "git add/rm <file>..." as appropriate to mark resolution)
@@ -195,6 +198,7 @@ test_expect_success 'status when conflicts with only rm advice (both deleted)' '
198 On branch conflict_second
199 You have unmerged paths.
200 (fix conflicts and run "git commit")
201 + (use "git merge --abort" to abort the merge)
202
203 Changes to be committed:
204
t/t7512-status-help.sh
+1
@@ -29,6 +29,7 @@ test_expect_success 'status when conflicts unresolved' '
29 On branch conflicts
30 You have unmerged paths.
31 (fix conflicts and run "git commit")
32 + (use "git merge --abort" to abort the merge)
33
34 Unmerged paths:
35 (use "git add <file>..." to mark resolution)
wt-status.c
+5 -2
@@ -946,9 +946,12 @@ static void show_merge_in_progress(struct wt_status *s,
946 {
947 if (has_unmerged(s)) {
948 status_printf_ln(s, color, _("You have unmerged paths."));
949 - if (s->hints)
949 + if (s->hints) {
950 status_printf_ln(s, color,
951 - _(" (fix conflicts and run \"git commit\")"));
951 + _(" (fix conflicts and run \"git commit\")"));
952 + status_printf_ln(s, color,
953 + _(" (use \"git merge --abort\" to abort the merge)"));
954 + }
955 } else {
956 status_printf_ln(s, color,
957 _("All conflicts fixed but you are still merging."));