I am working through the Git - Rerere section of the Git Book. I have just run git checkout master; git merge rerere2; git rerere diff. Here is the output.
PS> git rerere diff
--- a/simple.rb
+++ b/simple.rb
@@ -1,9 +1,9 @@
#! /usr/bin/env ruby
def hello
-<<<<<<<
- puts 'hello mondo'
-=======
+<<<<<<< HEAD
puts 'hola world'
->>>>>>>
+=======
+ puts 'hello mondo'
+>>>>>>> rerere2
end
There are three diff sections.
<<<<<<<shows what?<<<<<<< HEADshows what theHEADbranch wants to contribute.>>>>>>> rerere2shows what thererere2branch wants to contribute.
It looks like the first diff section is a negation of what rerere2 wants to contribute. That doesn't make sense to me, though. What does the first section mean?
From that link
git rerere diff will show the current state of the resolution - what you started with to resolve and what you've resolved it to.
git rerere saves merging choices. So it's describing the thing's it's going to do. First section is one of the inputs for resolution. Last section is the output of the merge.
This section is telling you what it's thinking about doing. It wants to take out hello mundo from one file and hola world from another and replace it with hello mundo.
Takes "hello mundo" and "hola world" and replaces that line with hola mundo