why does git mergetool say “No files need merging”?

I’m trying to configure BeyondCompare4 as my difftool and mergetool in git. I’m using git version 2.5.0.windows.1. So far BeyondCompare4 is working just fine as a difftool but not as a mergetool.

From my master branch I run git mergetool branch3 and it responds with No files need merging

  • Set up new project repository on windows LAN envirnment
  • Building a git bridge
  • Heroku thinks app is in same folder
  • How do I force a merge commit when the branch being merge has been merged and reverted already?
  • How can I use Git's malloc wrapper in my code?
  • Capistrano release not publishing
  • But when I run git diff branch3 I can see several types of differences in one file (often on the same line). And if I just run git merge branch3 it does start the merge process and stop with a CONFLICT. So why doesn’t git mergetool work for me in the same way?

    This link suggested git config --global core.trustctime false which I tried with no luck:
    git mergetool reports "No files need merging"

    This link suggested rerere may be a problem so I tried git config --global rerere.enabled false also with no luck:
    git tells me that I Merge conflict, but also tells me that no files need merging

    This is what my .gitconfig looks like:

        tool = bc
        prompt = false
    [difftool "bc"]
        trustExitCode = true
        cmd = 'c:/program files (x86)/beyond compare 4/bcomp.exe' $LOCAL $REMOTE
        tool = bc
         prompt = false
    [mergetool "bc"]
        trustExitCode = true
        cmd = 'c:/program files (x86)/beyond compare 4/bcomp.exe' $LOCAL $REMOTE $BASE $MERGED

    I even tried modifying .gitconfig to change the bcomp4.exe path to something bogus just to see if I could get an error. If I make the change to difftool I get errors about the system not finding the path. But if I change it on the mergetool it just keeps saying “No files need merging” which leads me to believe BeyondCompare4 is not even running.

    Thanks for any ideas why git mergetool is stopping early with that message.

  • Could we use Travis CI for Gitorious?
  • How to undo 'git fetch'
  • Git file renaming produces Error: “warning: destination exists; will overwrite!”
  • How and why does “git checkout HEAD” result in different results for “--theirs” and “--ours”?
  • How to organize and setup mirrored backup servers for Git repositories?
  • Do different versions of a file get their own blob/sha?
  • One Solution collect form web for “why does git mergetool say “No files need merging”?”

    You should use git mergetool when you are in a state where you need to resolve conflicts, that is, after a merge results in a conflict.

    git checkout master
    git merge branch3
    # the merge reports conflicts which we need to resolve
    git mergetool
    git add -u
    git commit -m "a merge commit message"

    More about resolving conflicts with meregetool can be found at https://git-scm.com/book/en/v2/Git-Branching-Basic-Branching-and-Merging#Basic-Merge-Conflicts

    Consult git help mergetool for options.

    Git Baby is a git and github fan, let's start git clone.