git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v2 1/3] Documentation/git-merge: explain --continue

From
hIpPy <hippy2981@gmail.com>
Date
Aug 22, 2017, 15:24 UTC
Message-ID
<CAM_JFCzq+DPUFbC60kjNjHz3OZLt-X3bLXJdSFpBnATtZ6otdA@mail.gmail.com>
In-Reply-To
<CAN0heSq0t=Jkaq-dgt_T4K9an4Peat0jArRQgE6JgsWwu53FPw@mail.gmail.com>

I think 'git merge --continue' should be advertised more that 'git commit' as typically one is familiar with 'git rebase --continue' and 'git cherry-pick --continue'. I for a long time did not know I could also use 'git commit' to continue a merge but that's just me. Now, 'git commit' is easier to remember if it works in all cases (merge, rebase, cherry-pick).

RM
On Tue, Aug 22, 2017 at 3:06 AM, Martin Ågren <martin.agren@gmail.com> wrote:
Show 55 quoted lines
> On 22 August 2017 at 11:26, Michael J Gruber <git@grubix.eu> wrote:
>> Martin Ågren venit, vidit, dixit 21.08.2017 18:43:
>>> On 21 August 2017 at 14:53, Michael J Gruber <git@grubix.eu> wrote:
>>>> Currently, 'git merge --continue' is mentioned but not explained.
>>>>
>>>> Explain it.
>>>>
>>>> Signed-off-by: Michael J Gruber <git@grubix.eu>
>>>> ---
>>>>  Documentation/git-merge.txt | 5 ++++-
>>>>  1 file changed, 4 insertions(+), 1 deletion(-)
>>>>
>>>> diff --git a/Documentation/git-merge.txt b/Documentation/git-merge.txt
>>>> index 6b308ab6d0..615e6bacde 100644
>>>> --- a/Documentation/git-merge.txt
>>>> +++ b/Documentation/git-merge.txt
>>>> @@ -288,7 +288,10 @@ After seeing a conflict, you can do two things:
>>>>
>>>>   * Resolve the conflicts.  Git will mark the conflicts in
>>>>     the working tree.  Edit the files into shape and
>>>> -   'git add' them to the index.  Use 'git commit' to seal the deal.
>>>> +   'git add' them to the index.  Use 'git commit' or
>>>> +   'git merge --continue' to seal the deal. The latter command
>>>> +   checks whether there is a (interrupted) merge in progress
>>>> +   before calling 'git commit'.
>>>>
>>>>  You can work through the conflict with a number of tools:
>>>
>>> There are actually two things going on here. First, this mentions git
>>> merge --continue. Second, it explains what that command does. But the
>>> latter is done earlier (not exactly like here, but still).
>>
>> I didn't see that explained in the man page at all - on the contrary, I
>> only saw a forward reference (see section...), but then only an
>> explanation of what "resolving" means (including the "git commit"-step).
>> It is unclear to me from the man page which steps of "resolving" the
>> command "git merge --continue" does - you could think it does "git
>> commit -a", for example.
>
> That's very true, and your change helps immensely. I thought that once
> git merge --continue was mentioned, e.g.,
>
>         Use 'git commit' or 'git merge --continue' to seal the deal.
>
> or
>
>         Use 'git commit' to conclude (you can also say 'git merge
>         --continue').
>
> then things are in some sense "complete". But you might be right that
> further stressing that the latter is basically an alias helps avoid some
> confusion. "Oh, great, so now I have two commands to choose from -- which
> one should I be using?" :-)
>
> Martin
Previous: Martin ÅgrenNext: Junio C Hamano
Message 8 of 22 in “Git makes a merge commit but as a normal (non-merge) commit”
  1. hIpPyAug 18, 2017
  2. Michael J GruberAug 21, 2017
  3. merge: save merge state earlierMichael J Gruber, Aug 21, 2017
  4. 1/3 Documentation/git-merge: explain --continueMichael J Gruber, Aug 21, 2017
  5. Martin ÅgrenAug 21, 2017
  6. Michael J GruberAug 22, 2017
  7. Martin ÅgrenAug 22, 2017
  8. hIpPyAug 22, 2017
  9. Junio C HamanoAug 22, 2017
  10. 1/4 Documentation/git-merge: explain --continueMichael J Gruber, Aug 23, 2017
  11. 0/4 Keep merge during killsMichael J Gruber, Aug 23, 2017
  12. 2/4 merge: clarify call chainMichael J Gruber, Aug 23, 2017
  13. 3/4 merge: split write_merge_state in twoMichael J Gruber, Aug 23, 2017
  14. 4/4 merge: save merge state earlierMichael J Gruber, Aug 23, 2017
  15. Junio C HamanoAug 22, 2017
  16. 3/3 merge: save merge state earlierMichael J Gruber, Aug 21, 2017
  17. Junio C HamanoAug 22, 2017
  18. Michael J GruberAug 22, 2017
  19. Junio C HamanoAug 22, 2017
  20. 0/3 Keep merge during killsMichael J Gruber, Aug 21, 2017
  21. 2/3 merge: split write_merge_state in twoMichael J Gruber, Aug 21, 2017
  22. Junio C HamanoAug 22, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.