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

Re: git-rerere observations and feature suggestions

From
PZPeter Zijlstra <peterz@infradead.org>
Date
Jun 23, 2008, 14:26 UTC
Message-ID
<1214231197.3223.332.camel@lappy.programming.kicks-ass.net>
In-Reply-To
<1214230796.3223.326.camel@lappy.programming.kicks-ass.net>
On Mon, 2008-06-23 at 16:20 +0200, Peter Zijlstra wrote:
Show 35 quoted lines
> On Mon, 2008-06-23 at 11:49 +0200, Ingo Molnar wrote:
> > another git-rerere observation: occasionally it happens that i 
> > accidentally commit a merge marker into the source code.
> > 
> > That's obviously stupid, and it normally gets found by testing quickly, 
> > but still it would be a really useful avoid-shoot-self-in-foot feature 
> > if git-commit could warn about such stupidities of mine.
> > 
> > ( and if i could configure git-commit to outright reject a commit like 
> >   that - i never want to commit lines with <<<<<< or >>>>> markers)
> > 
> > Another merge conflict observation is that Git is much worse at figuring 
> > out the right merge resolution than our previous Quilt based workflow 
> > was. I eventually found it to be mainly due to the following detail: 
> > sometimes it's more useful to first apply the merged branch and then 
> > attempt to merge HEAD, as a patch.
> > 
> > I've got a script for that which also combines it with the "rej" tool, 
> > and in about 70%-80% of the cases where Git is unable to resolve a merge 
> > automatically it figures things out. ('rej' is obviously a more relaxed 
> > merge utility, but it's fairly robust in my experience, with a very low 
> > false positive rate.)
> > 
> > The ad-hoc "tip-mergetool" script we are using is attached below. It's 
> > really just for demonstration purposes - it doesnt work when there's a 
> > rename related conflict, etc.
> > 
> > Peter Zijstra also wrote a git-mergetool extension for the 'rej' tool 
> > btw., he might want to post that patch. I've attached Chris Mason's rej 
> > tool too.
> 
> This is what I run with.
> 
> I added the cp to the 3-way merge tools because I think its stupid to
> see the messed up merge markers instead of the original file.

While we're on the subject, I only found one tool that 'digs' these merge markers and that is xxdiff --unmerge.

One would think more tools understand these merge markers, but I couldn't find any.

Previous: Peter ZijlstraNext: Jeff King
Message 41 of 45 in “git-rerere observations and feature suggestions”
  1. Ingo MolnarJun 16, 2008
  2. Mike HommeyJun 16, 2008
  3. Pierre HabouzitJun 16, 2008
  4. Pierre HabouzitJun 16, 2008
  5. Sverre RabbelierJun 16, 2008
  6. Karl HasselströmJun 17, 2008
  7. David KastrupJun 16, 2008
  8. Theodore TsoJun 16, 2008
  9. David KastrupJun 16, 2008
  10. Ingo MolnarJun 16, 2008
  11. Junio C HamanoJun 16, 2008
  12. Ingo MolnarJun 16, 2008
  13. Junio C HamanoJun 16, 2008
  14. Junio C HamanoJun 16, 2008
  15. Ingo MolnarJun 16, 2008
  16. Junio C HamanoJun 16, 2008
  17. 1/5 rerere: rerere_created_at() and has_resolution() abstractionJunio C Hamano, Jun 22, 2008
  18. 2/5 git-rerere: detect unparsable conflictsJunio C Hamano, Jun 22, 2008
  19. 3/5 rerere: remove dubious "tail_optimization"Junio C Hamano, Jun 22, 2008
  20. 4/5 t4200: fix rerere testJunio C Hamano, Jun 22, 2008
  21. 5/5 rerere.autoupdateJunio C Hamano, Jun 22, 2008
  22. Ingo MolnarJun 18, 2008
  23. Miklos VajnaJun 18, 2008
  24. Ingo MolnarJun 18, 2008
  25. Miklos VajnaJun 18, 2008
  26. Ingo MolnarJun 18, 2008
  27. Jakub NarebskiJun 18, 2008
  28. Miklos VajnaJun 18, 2008
  29. Karl HasselströmJun 19, 2008
  30. Miklos VajnaJun 19, 2008
  31. Junio C HamanoJun 19, 2008
  32. Karl HasselströmJun 19, 2008
  33. Miklos VajnaJun 19, 2008
  34. Karl HasselströmJun 19, 2008
  35. Miklos VajnaJun 19, 2008
  36. Karl HasselströmJun 19, 2008
  37. Junio C HamanoJun 16, 2008
  38. Ingo MolnarJun 16, 2008
  39. Ingo MolnarJun 23, 2008
  40. Peter ZijlstraJun 23, 2008
  41. Peter ZijlstraJun 23, 2008
  42. Jeff KingJun 23, 2008
  43. Ingo MolnarJun 23, 2008
  44. Jakub NarebskiJun 16, 2008
  45. Johannes SchindelinJun 17, 2008

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.