Git merge left HEAD marks in my files

Those are conflict markers. You’re still in the process of merging, but there were some parts that Git couldn’t merge automatically. You’ll need to hand-edit those parts to what you want them to be and then commit the results.


For instance, in your particular case, you’d probably want to resolve it like this (note – the arrows/text on the right are just my notes, not something you’d type into the file):

integer = 
<<<<<<< HEAD                                  <-+ remove the bits here
    digits:[0-9]+                               |
        { return digits.join(""); }             |
=======                                       <-+
    sign:"-"* digits:[0-9]+
        { return sign + digits.join(""); }
>>>>>>> gh-pages                              <-- and this

and thus you’d save the file as…

integer = 
    sign:"-"* digits:[0-9]+
        { return sign + digits.join(""); }

Leave a Comment