Skip to contentSkip to conversation

status: suggest `git merge --continue`, not `git commit`

PATCH Superseded Julia Evans via GitGitGadget 5 participants 11 messages Oct 6 – Oct 9

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 status: suggest `git merge --continue`, not `git commit`

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent.
Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use
git merge --continue.

---
status: suggest git merge --continue, not git commit

We discussed making this consistent in another thread:
https://lore.kernel.org/git/[email protected]/T/#m4bdcb555cbdff4132fb1a678594f26b598e0b38f

From some research:

* git merge --continue was introduced in 367ff694281c in Dec 2016. It says that git merge --continue is intended to be a synonym for git commit. (thread here:
https://lore.kernel.org/git/[email protected]/)
* This line of the advice was last touched in July 2016, before git merge --continue was introduced.

So I don't see any obvious reason not to change the advice.

Translations will need to be updated, I still don't know how that process works. Updating the translations should be straightforward since it's just a change in the command.

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-2249%2Fjvns%2Fadvice-merge-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-2249/jvns/advice-merge-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/2249

 t/t7060-wtstatus.sh    | 8 ++++----
 t/t7512-status-help.sh | 4 ++--
 wt-status.c            | 4 ++--
 3 files changed, 8 insertions(+), 8 deletions(-)
t/t7060-wtstatus.sh +4 -4
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
 	cat >expect <<EOF &&
 On branch side
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -141,7 +141,7 @@ test_expect_success 'status when conflicts with add and rm advice (deleted by th
 	cat >expected <<\EOF &&
 On branch main
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -174,7 +174,7 @@ test_expect_success 'status when conflicts with add and rm advice (both deleted)
 	cat >expected <<\EOF &&
 On branch conflict_second
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -198,7 +198,7 @@ test_expect_success 'status when conflicts with only rm advice (both deleted)' '
 	cat >expected <<\EOF &&
 On branch conflict_second
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Changes to be committed:
t/t7512-status-help.sh +2 -2
index aca4b6d332..776a0dd5b8 100755
@@ -31,7 +31,7 @@ test_expect_success 'status when conflicts unresolved' '
 	cat >expected <<\EOF &&
 On branch conflicts
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -53,7 +53,7 @@ test_expect_success 'status when conflicts resolved before commit' '
 	cat >expected <<\EOF &&
 On branch conflicts
 All conflicts fixed but you are still merging.
-  (use "git commit" to conclude merge)
+  (use "git merge --continue" to conclude merge)
 
 Changes to be committed:
 	modified:   main.txt
wt-status.c +2 -2
index 57772c7501..f7b0dc29d5 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
 		status_printf_ln(s, color, _("You have unmerged paths."));
 		if (s->hints) {
 			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
 			status_printf_ln(s, color,
 					 _("  (use \"git merge --abort\" to abort the merge)"));
 		}
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
 			_("All conflicts fixed but you are still merging."));
 		if (s->hints)
 			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude merge)"));
 	}
 	wt_longstatus_print_trailer(s);
 }

base-commit: 5a7d1e8045ce66c908f62598e26cbb8df7b39a90

Signature · 1 line
gitgitgadget
#1 lore raw

Hi Julia

Quoted 7 lines · Julia Evans via GitGitGadget

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent. Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that

When we use the output of "git show -s --format=reference" when referring to previous commits, so this would be

367ff69428 (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14)

Quoted 3 lines

git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use
git merge --continue.

This looks like a sensible improvement. I wonder if we should fix the grammar at the same time so it says

(use "git merge --continue" to conclude the merge)

rather than

(use "git merge --continue" to conclude merge)

Thanks

Phillip

Quoted 117 lines

---
status: suggest git merge --continue, not git commit

We discussed making this consistent in another thread:
https://lore.kernel.org/git/[email protected]/T/#m4bdcb555cbdff4132fb1a678594f26b598e0b38f

From some research:

* git merge --continue was introduced in 367ff694281c in Dec 2016. It says that git merge --continue is intended to be a synonym for git commit. (thread here:
https://lore.kernel.org/git/[email protected]/)
* This line of the advice was last touched in July 2016, before git merge --continue was introduced.

So I don't see any obvious reason not to change the advice.

Translations will need to be updated, I still don't know how that process works. Updating the translations should be straightforward since it's just a change in the command.

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-2249%2Fjvns%2Fadvice-merge-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-2249/jvns/advice-merge-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/2249

  t/t7060-wtstatus.sh    | 8 ++++----
  t/t7512-status-help.sh | 4 ++--
  wt-status.c            | 4 ++--
  3 files changed, 8 insertions(+), 8 deletions(-)
t/t7060-wtstatus.sh +4 -4
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
  	cat >expect <<EOF &&
  On branch side
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -141,7 +141,7 @@ test_expect_success 'status when conflicts with add and rm advice (deleted by th
  	cat >expected <<\EOF &&
  On branch main
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -174,7 +174,7 @@ test_expect_success 'status when conflicts with add and rm advice (both deleted)
  	cat >expected <<\EOF &&
  On branch conflict_second
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -198,7 +198,7 @@ test_expect_success 'status when conflicts with only rm advice (both deleted)' '
  	cat >expected <<\EOF &&
  On branch conflict_second
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Changes to be committed:
t/t7512-status-help.sh +2 -2
index aca4b6d332..776a0dd5b8 100755
@@ -31,7 +31,7 @@ test_expect_success 'status when conflicts unresolved' '
  	cat >expected <<\EOF &&
  On branch conflicts
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -53,7 +53,7 @@ test_expect_success 'status when conflicts resolved before commit' '
  	cat >expected <<\EOF &&
  On branch conflicts
  All conflicts fixed but you are still merging.
-  (use "git commit" to conclude merge)
+  (use "git merge --continue" to conclude merge)
 
  Changes to be committed:
  	modified:   main.txt
wt-status.c +2 -2
index 57772c7501..f7b0dc29d5 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
  		status_printf_ln(s, color, _("You have unmerged paths."));
  		if (s->hints) {
  			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
  			status_printf_ln(s, color,
  					 _("  (use \"git merge --abort\" to abort the merge)"));
  		}
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
  			_("All conflicts fixed but you are still merging."));
  		if (s->hints)
  			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude merge)"));
  	}
  	wt_longstatus_print_trailer(s);
  }

base-commit: 5a7d1e8045ce66c908f62598e26cbb8df7b39a90

#3 lore raw
In reply to Julia Evans via GitGitGadget

"Julia Evans via GitGitGadget" <[email protected]> writes:

[Administrivia]

As you have

cc D. Ben Knoble" [email protected]

at the end of your pull request that you gave to GitGitGadget, you ended up with a bogus Cc: address that reads

"D. Ben Knoble <ben.knoble"@gmail.com>

you may want to help improving GGG by raising an issue to reject (or ignore) such a malformed address.

[end of administrivia]

t/t7060-wtstatus.sh test_expect_success 'M/D conflict does not segfault' ' · line 41

Quoted 11 lines
t/t7060-wtstatus.sh +1 -1
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
 	cat >expect <<EOF &&
 On branch side
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)

This message comes from show_merge_in_progress(), which is called only when the code is convinced that it is seeing an unmerged index due to a conflicted git merge. We can therefore make this message as merge-specific as we want. The suggestion to use 'git merge --abort' already does this.

Quoted 14 lines
wt-status.c +1 -1
index 57772c7501..f7b0dc29d5 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
 		status_printf_ln(s, color, _("You have unmerged paths."));
 		if (s->hints) {
 			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
 			status_printf_ln(s, color,
 					 _("  (use \"git merge --abort\" to abort the merge)"));
 		}

wt-status.c static void show_merge_in_progress(struct wt_status *s, · line 1288

Quoted 8 lines
wt-status.c +1 -1
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
 			_("All conflicts fixed but you are still merging."));
 		if (s->hints)
 			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude merge)"));
 	}
 	wt_longstatus_print_trailer(s);
 }

We could tighten "You have unmerged paths." even further to indicate that these paths came from a conflicted 'git merge'. In the same file, show_cherry_pick_in_progress() and show_revert_in_progress() already provide instructions very specific to these commands. Since the message for 'git merge' is the oldest, it is not surprising that we did not update it when 'git merge --continue', the instructions for cherry-pick and revert, or 'git merge --abort' instruction were added to the system. This commit moves us belatedly in the right direction, and as always, it is better late than never.

The changes look good. Thanks.

#2 lore raw
In reply to Phillip Wood
Quoted 4 lines
Quoted 4 lines

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Quoted 8 lines
Quoted 2 lines

Change the git merge advice to be consistent. Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that

When we use the output of "git show -s --format=reference" when referring to previous commits, so this would be

367ff69428 (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14)

Thanks, will fix in v2.

Quoted 4 lines
Quoted 3 lines

git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use
git merge --continue.

Quoted 8 lines

This looks like a sensible improvement. I wonder if we should fix the grammar at the same time so it says

(use "git merge --continue" to conclude the merge)

rather than

(use "git merge --continue" to conclude merge)

Makes sense to me, will change that too.

#4 lore raw
In reply to Junio C Hamano
Quoted 8 lines · Junio C Hamano

"Julia Evans via GitGitGadget" <[email protected]> writes:

[Administrivia]

As you have

cc D. Ben Knoble" [email protected]
Quoted 7 lines

at the end of your pull request that you gave to GitGitGadget, you ended up with a bogus Cc: address that reads

"D. Ben Knoble <ben.knoble"@gmail.com>

you may want to help improving GGG by raising an issue to reject (or ignore) such a malformed address.

done: https://github.com/gitgitgadget/gitgitgadget/issues/2385

Quoted 44 lines

[end of administrivia]

t/t7060-wtstatus.sh test_expect_success 'M/D conflict does not segfault' ' · line 41

Quoted 11 lines
t/t7060-wtstatus.sh +1 -1
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
 	cat >expect <<EOF &&
 On branch side
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)

This message comes from show_merge_in_progress(), which is called only when the code is convinced that it is seeing an unmerged index due to a conflicted git merge. We can therefore make this message as merge-specific as we want. The suggestion to use 'git merge --abort' already does this.

Quoted 14 lines
wt-status.c +1 -1
index 57772c7501..f7b0dc29d5 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
 		status_printf_ln(s, color, _("You have unmerged paths."));
 		if (s->hints) {
 			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
 			status_printf_ln(s, color,
 					 _("  (use \"git merge --abort\" to abort the merge)"));
 		}

wt-status.c static void show_merge_in_progress(struct wt_status *s, · line 1288

Quoted 8 lines
wt-status.c +1 -1
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
 			_("All conflicts fixed but you are still merging."));
 		if (s->hints)
 			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude merge)"));
 	}
 	wt_longstatus_print_trailer(s);
 }

We could tighten "You have unmerged paths." even further to indicate

Quoted 8 lines

that these paths came from a conflicted 'git merge'. In the same file, show_cherry_pick_in_progress() and show_revert_in_progress() already provide instructions very specific to these commands. Since the message for 'git merge' is the oldest, it is not surprising that we did not update it when 'git merge --continue', the instructions for cherry-pick and revert, or 'git merge --abort' instruction were added to the system. This commit moves us belatedly in the right direction, and as always, it is better late than never.

Yeah I agree that "You have unmerged paths." could likely be made clearer. Appreciate the note about how the implementation works.

Quoted 1 line

The changes look good. Thanks.

#5 lore raw

PATCH v2 1/1 status: suggest `git merge --continue`, not `git commit`

In reply to Julia Evans via GitGitGadget

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent.
Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use
git merge --continue.

---
status: suggest git merge --continue, not git commit

Changes in v2:

* Use git show -s --format=reference to format the reference in the commit message (thanks to Phillip)
* change to "conclude the merge" (thanks to Phillip)

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-2249%2Fjvns%2Fadvice-merge-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-2249/jvns/advice-merge-v2
Pull-Request: https://github.com/gitgitgadget/git/pull/2249

Range-diff vs v1:

1: 551b0e79b0 ! 1: afc69ffeb8 status: suggest git merge --continue, not git commit
@@ t/t7512-status-help.sh: test_expect_success 'status when conflicts resolved befo
On branch conflicts
All conflicts fixed but you are still merging.
- (use "git commit" to conclude merge)
-+ (use "git merge --continue" to conclude merge)
++ (use "git merge --continue" to conclude the merge)

Changes to be committed:
modified: main.txt
@@ wt-status.c: static void show_merge_in_progress(struct wt_status *s,
if (s->hints)
status_printf_ln(s, color,
- _(" (use \"git commit\" to conclude merge)"));
-+ _(" (use \"git merge --continue\" to conclude merge)"));
++ _(" (use \"git merge --continue\" to conclude the merge)"));
}
wt_longstatus_print_trailer(s);
}

 t/t7060-wtstatus.sh    | 8 ++++----
 t/t7512-status-help.sh | 4 ++--
 wt-status.c            | 4 ++--
 3 files changed, 8 insertions(+), 8 deletions(-)
t/t7060-wtstatus.sh +4 -4
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
 	cat >expect <<EOF &&
 On branch side
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -141,7 +141,7 @@ test_expect_success 'status when conflicts with add and rm advice (deleted by th
 	cat >expected <<\EOF &&
 On branch main
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -174,7 +174,7 @@ test_expect_success 'status when conflicts with add and rm advice (both deleted)
 	cat >expected <<\EOF &&
 On branch conflict_second
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -198,7 +198,7 @@ test_expect_success 'status when conflicts with only rm advice (both deleted)' '
 	cat >expected <<\EOF &&
 On branch conflict_second
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Changes to be committed:
t/t7512-status-help.sh +2 -2
index aca4b6d332..f2e712ac39 100755
@@ -31,7 +31,7 @@ test_expect_success 'status when conflicts unresolved' '
 	cat >expected <<\EOF &&
 On branch conflicts
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -53,7 +53,7 @@ test_expect_success 'status when conflicts resolved before commit' '
 	cat >expected <<\EOF &&
 On branch conflicts
 All conflicts fixed but you are still merging.
-  (use "git commit" to conclude merge)
+  (use "git merge --continue" to conclude the merge)
 
 Changes to be committed:
 	modified:   main.txt
wt-status.c +2 -2
index 57772c7501..238bb48643 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
 		status_printf_ln(s, color, _("You have unmerged paths."));
 		if (s->hints) {
 			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
 			status_printf_ln(s, color,
 					 _("  (use \"git merge --abort\" to abort the merge)"));
 		}
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
 			_("All conflicts fixed but you are still merging."));
 		if (s->hints)
 			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude the merge)"));
 	}
 	wt_longstatus_print_trailer(s);
 }

base-commit: 5a7d1e8045ce66c908f62598e26cbb8df7b39a90

Signature · 1 line
gitgitgadget
#6 lore raw
Quoted 7 lines · Julia Evans via GitGitGadget

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent. Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that

Quoted 7 lines
[snip]
[snip]

Changes in v2:

* Use git show -s --format=reference to format the reference in the commit message (thanks to Phillip)

But this isn’t changed?

You can use this commit --amend snippet to change it. It worked for me at least.

    cat >rewrite-msg.sh <<-\EOF
    #!/bin/sh

    file="$1"
    git format-rev --stdin-mode=text --format=reference <"$file" \
        | par g0 \
        | sponge "$file"
    EOF
    chmod +x rewrite-msg.sh
    GIT_EDITOR=./rewrite-msg.sh git commit --amend
Quoted 3 lines

* change to "conclude the merge" (thanks to Phillip)

[snip]

#8 lore raw

PATCH v3 1/1 status: suggest `git merge --continue`, not `git commit`

In reply to Julia Evans via GitGitGadget

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent. 367ff69428 (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14) says that git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use git merge --continue.

---
status: suggest git merge --continue, not git commit

Changes in v2:

* Use git show -s --format=reference to format the reference in the commit message (thanks to Phillip)
* change to "conclude the merge" (thanks to Phillip)

Changes in v3:

* Actually format the reference correctly (oops)

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-2249%2Fjvns%2Fadvice-merge-v3
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-2249/jvns/advice-merge-v3
Pull-Request: https://github.com/gitgitgadget/git/pull/2249

Range-diff vs v2:

1: afc69ffeb8 ! 1: 27678e07a8 status: suggest git merge --continue, not git commit
@@ Commit message
During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

- Change the git merge advice to be consistent.
- Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that
- git merge --continue is intended to be a synonym for git commit,
- and the git merge man page already suggests to use
+ Change the git merge advice to be consistent. 367ff69428
+ (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14)
+ says that git merge --continue is intended to be a synonym for
+ git commit, and the git merge man page already suggests to use
git merge --continue.

 t/t7060-wtstatus.sh    | 8 ++++----
 t/t7512-status-help.sh | 4 ++--
 wt-status.c            | 4 ++--
 3 files changed, 8 insertions(+), 8 deletions(-)
t/t7060-wtstatus.sh +4 -4
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
 	cat >expect <<EOF &&
 On branch side
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -141,7 +141,7 @@ test_expect_success 'status when conflicts with add and rm advice (deleted by th
 	cat >expected <<\EOF &&
 On branch main
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -174,7 +174,7 @@ test_expect_success 'status when conflicts with add and rm advice (both deleted)
 	cat >expected <<\EOF &&
 On branch conflict_second
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -198,7 +198,7 @@ test_expect_success 'status when conflicts with only rm advice (both deleted)' '
 	cat >expected <<\EOF &&
 On branch conflict_second
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Changes to be committed:
t/t7512-status-help.sh +2 -2
index aca4b6d332..f2e712ac39 100755
@@ -31,7 +31,7 @@ test_expect_success 'status when conflicts unresolved' '
 	cat >expected <<\EOF &&
 On branch conflicts
 You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
   (use "git merge --abort" to abort the merge)
 
 Unmerged paths:
@@ -53,7 +53,7 @@ test_expect_success 'status when conflicts resolved before commit' '
 	cat >expected <<\EOF &&
 On branch conflicts
 All conflicts fixed but you are still merging.
-  (use "git commit" to conclude merge)
+  (use "git merge --continue" to conclude the merge)
 
 Changes to be committed:
 	modified:   main.txt
wt-status.c +2 -2
index 57772c7501..238bb48643 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
 		status_printf_ln(s, color, _("You have unmerged paths."));
 		if (s->hints) {
 			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
 			status_printf_ln(s, color,
 					 _("  (use \"git merge --abort\" to abort the merge)"));
 		}
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
 			_("All conflicts fixed but you are still merging."));
 		if (s->hints)
 			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude the merge)"));
 	}
 	wt_longstatus_print_trailer(s);
 }

base-commit: 5a7d1e8045ce66c908f62598e26cbb8df7b39a90

Signature · 1 line
gitgitgadget
#7 lore raw
In reply to Kristoffer Haugsbakk
Quoted 13 lines · Julia Evans via GitGitGadget
Quoted 12 lines

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent. Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that

[snip]
[snip]

Changes in v2:

Quoted 4 lines
Quoted 2 lines

* Use git show -s --format=reference to format the reference in the commit message (thanks to Phillip)

But this isn’t changed?

Oops, I was so sure that I'd changed it but obviously not. Sent a v3 with it changed.

#9 lore raw
In reply to Julia Evans via GitGitGadget

Hi Julia

Quoted 10 lines · Julia Evans via GitGitGadget

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent. 367ff69428 (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14) says that git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use git merge --continue.

This version looks good to me, thanks for working on it

Phillip

Quoted 129 lines

---
status: suggest git merge --continue, not git commit

Changes in v2:

* Use git show -s --format=reference to format the reference in the commit message (thanks to Phillip)
* change to "conclude the merge" (thanks to Phillip)

Changes in v3:

* Actually format the reference correctly (oops)

Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-2249%2Fjvns%2Fadvice-merge-v3
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-2249/jvns/advice-merge-v3
Pull-Request: https://github.com/gitgitgadget/git/pull/2249

Range-diff vs v2:

1: afc69ffeb8 ! 1: 27678e07a8 status: suggest git merge --continue, not git commit
@@ Commit message
During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

- Change the git merge advice to be consistent.
- Commit 367ff694281ce569edd8f6e444fc770f92f5d215 says that
- git merge --continue is intended to be a synonym for git commit,
- and the git merge man page already suggests to use
+ Change the git merge advice to be consistent. 367ff69428
+ (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14)
+ says that git merge --continue is intended to be a synonym for
+ git commit, and the git merge man page already suggests to use
git merge --continue.

  t/t7060-wtstatus.sh    | 8 ++++----
  t/t7512-status-help.sh | 4 ++--
  wt-status.c            | 4 ++--
  3 files changed, 8 insertions(+), 8 deletions(-)
t/t7060-wtstatus.sh +4 -4
index 942ddbbf0e..a9b435b5e3 100755
@@ -37,7 +37,7 @@ test_expect_success 'M/D conflict does not segfault' '
  	cat >expect <<EOF &&
  On branch side
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -141,7 +141,7 @@ test_expect_success 'status when conflicts with add and rm advice (deleted by th
  	cat >expected <<\EOF &&
  On branch main
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -174,7 +174,7 @@ test_expect_success 'status when conflicts with add and rm advice (both deleted)
  	cat >expected <<\EOF &&
  On branch conflict_second
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -198,7 +198,7 @@ test_expect_success 'status when conflicts with only rm advice (both deleted)' '
  	cat >expected <<\EOF &&
  On branch conflict_second
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Changes to be committed:
t/t7512-status-help.sh +2 -2
index aca4b6d332..f2e712ac39 100755
@@ -31,7 +31,7 @@ test_expect_success 'status when conflicts unresolved' '
  	cat >expected <<\EOF &&
  On branch conflicts
  You have unmerged paths.
-  (fix conflicts and run "git commit")
+  (fix conflicts and run "git merge --continue")
    (use "git merge --abort" to abort the merge)
 
  Unmerged paths:
@@ -53,7 +53,7 @@ test_expect_success 'status when conflicts resolved before commit' '
  	cat >expected <<\EOF &&
  On branch conflicts
  All conflicts fixed but you are still merging.
-  (use "git commit" to conclude merge)
+  (use "git merge --continue" to conclude the merge)
 
  Changes to be committed:
  	modified:   main.txt
wt-status.c +2 -2
index 57772c7501..238bb48643 100644
@@ -1273,7 +1273,7 @@ static void show_merge_in_progress(struct wt_status *s,
  		status_printf_ln(s, color, _("You have unmerged paths."));
  		if (s->hints) {
  			status_printf_ln(s, color,
-					 _("  (fix conflicts and run \"git commit\")"));
+					 _("  (fix conflicts and run \"git merge --continue\")"));
  			status_printf_ln(s, color,
  					 _("  (use \"git merge --abort\" to abort the merge)"));
  		}
@@ -1282,7 +1282,7 @@ static void show_merge_in_progress(struct wt_status *s,
  			_("All conflicts fixed but you are still merging."));
  		if (s->hints)
  			status_printf_ln(s, color,
-				_("  (use \"git commit\" to conclude merge)"));
+				_("  (use \"git merge --continue\" to conclude the merge)"));
  	}
  	wt_longstatus_print_trailer(s);
  }

base-commit: 5a7d1e8045ce66c908f62598e26cbb8df7b39a90

#10 lore raw
Quoted 14 lines · Phillip Wood

Hi Julia

Quoted 10 lines · Julia Evans via GitGitGadget

From: Julia Evans <[email protected]>

During a merge conflict, we suggest using --continue to continue the merge for rebase, revert, and cherry-pick.

Change the git merge advice to be consistent. 367ff69428 (merge: add '--continue' option as a synonym for 'git commit', 2016-12-14) says that git merge --continue is intended to be a synonym for git commit, and the git merge man page already suggests to use git merge --continue.

Quoted 3 lines

This version looks good to me, thanks for working on it

Phillip

Will apply with your Acked-by: and mark the topic for 'next'.

Thanks.