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

Re: [PATCH v4] user-manual: Add section "Why bisecting merge commits can be harder ..."

From
Steffen Prohaska <prohaska@zib.de>
Date
Nov 10, 2007, 22:41 UTC
Message-ID
<901775B5-D4BE-4CF1-BB0A-4FEF88D7880A@zib.de>
In-Reply-To
<7vtzntlufh.fsf@gitster.siamese.dyndns.org>
On Nov 10, 2007, at 9:25 PM, Junio C Hamano wrote:
Show 53 quoted lines
> Linus Torvalds <torvalds@linux-foundation.org> writes:
>
>> On Sat, 10 Nov 2007, Steffen Prohaska wrote:
>>> +
>>> +But if you already made a merge C instead of rebasing, all
>>> +is not lost.  In the illustrated case, you can easily rebase
>>> +one parent branch on top of the other after the fact, just
>>> +to understand the history and to make the history more
>>> +easily to bisect.
>>
>> I simply don't think this is true.
>>
>> You can *not* easily rebase after the fact. Both the parents may  
>> have lots
>> of merges independently of each other, and rebase won't be able to do
>> *anything* with such a case. In fact, the only reason you think  
>> you can
>> easily rebase after-the-fact is that you made the example history be
>> trivial. In real life, if the example history is that trivial (just a
>> single merge of two otherwise linear histories), you'd probably  
>> generally
>> not have this problem in the first place.
>>
>> The facts are:
>>
>>  - git bisect can handle merges quite well, and points to the right
>>    commit (which is *usually* not a merge).
>>
>>  - but merges by definition introduce changes from two independent  
>> lines
>>    of development, and while both lines may work well on their  
>> own, it is
>>    possible that (a) the merge itself was done incorrectly or (b)  
>> the two
>>    (or more) features that were introduced simply clash.
>>
>>  - "git rebase" won't do a thing for this after the fact, except in
>>    trivial cases, and even then it will generate a new history  
>> that simply
>>    isn't compatible with the original history, so while it could  
>> in theory
>>    help bisect things further in some limited and simple cases, in  
>> general
>>    it's simply not that useful an approach.
>>
>> ..and I think it's simply wrong to even *try* to imply that "git  
>> rebase"
>> can somehow change any of this.
>
> Very true.  It is a suggestion useful _only_ when you can easily
> rebase.  Like the one illustrated in the description, which is
> artificial and of very limited scope.  If you cannot rebase
> easily, then (by definition) rebase would not help you.

I propose to remove this suggestion if no one comes up with a real world example where rebasing after the fact turned out to be useful. If nobody has such an example it doesn't make sense to tell readers of the manual that rebase could be useful in such a situation.

The patch would be identical except for the last paragraph removed.

	Steffen
Previous: Junio C HamanoNext: J. Bruce Fields
Message 21 of 30 in “user-manual: add advanced topic "bisecting merges"”
  1. user-manual: add advanced topic "bisecting merges"Steffen Prohaska, Nov 4, 2007
  2. Ralf WildenhuesNov 4, 2007
  3. user-manual: add advanced topic "bisecting merges"Steffen Prohaska, Nov 7, 2007
  4. Benoit SigoureNov 7, 2007
  5. J. Bruce FieldsNov 7, 2007
  6. Steffen ProhaskaNov 8, 2007
  7. Johannes SixtNov 8, 2007
  8. Steffen ProhaskaNov 8, 2007
  9. Johannes SixtNov 8, 2007
  10. Andreas EricssonNov 8, 2007
  11. Johannes SixtNov 8, 2007
  12. Steffen ProhaskaNov 8, 2007
  13. Johannes SixtNov 8, 2007
  14. Steffen ProhaskaNov 8, 2007
  15. user-manual: add advanced topic "bisecting merges"Steffen Prohaska, Nov 10, 2007
  16. Junio C HamanoNov 10, 2007
  17. Steffen ProhaskaNov 10, 2007
  18. user-manual: Add section "Why bisecting merge commits can be harder ..."Steffen Prohaska, Nov 10, 2007
  19. Linus TorvaldsNov 10, 2007
  20. Junio C HamanoNov 10, 2007
  21. Steffen ProhaskaNov 10, 2007
  22. J. Bruce FieldsNov 18, 2007
  23. Steffen ProhaskaNov 18, 2007
  24. J. Bruce FieldsNov 18, 2007
  25. Andreas EricssonNov 8, 2007
  26. Benoit SigoureNov 8, 2007
  27. Steffen ProhaskaNov 8, 2007
  28. Johannes SchindelinNov 8, 2007
  29. Brian GernhardtNov 8, 2007
  30. Benoit SIGOURENov 4, 2007

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.