Git, Windows, difftool

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • johnkors
    Visitor
    • Apr 2013
    • 4

    Git, Windows, difftool

    Hi,

    I'm trying to use bcomp as a diff tool on windows with git. My global git config is set to

    [diff]
    tool = bc3
    [difftool "bc3"]
    path = c:/program files (x86)/beyond compare 3/bcomp.exe

    When I use it by calling "git difftool" in my repo, it opens Bcomp in merge mode, and not in diff mode. What gives?

    Git version 1.8.0
    (installed with GitHub for Windows)

    /John
  • Aaron
    Team Scooter
    • Oct 2007
    • 15997

    #2
    Hello,

    That configuration looks correct (as implemented following our guide here):
    http://www.scootersoftware.com/suppo...vcs#gitwindows

    What information is in the Text Merge session type? Are three files passed as input (no output)? Or Are there two input panes and a declared output file?

    To see the command that Git is calling BC3 with, you can use a program like Process Explorer:
    http://technet.microsoft.com/en-us/s.../bb896653.aspx

    Have Git launch the diff, then look at Process Explorer and find the entry for Bcompare.exe and note the command line that was used to launch bcompare.exe. Would you be able to post it here or email it to [email protected]? If you email, please include a link to this forum thread.
    Aaron P Scooter Software

    Comment

    • johnkors
      Visitor
      • Apr 2013
      • 4

      #3
      Hi Aaron,

      this is what Process Explorer gives me when I do a git difftool and opens 3-way merge instead of text diff

      "c:\program files (x86)\beyond compare 3\bcomp.exe" C:/Users/myusername/AppData/Local/Temp/GwYvMa_MyFileHere.txt FullPath/MyFilehere.txt FullPath/MyFilehere.txt FullPath/MyFilehere.txt /BCompWnd=$00040BFA
      Last edited by johnkors; 30-Apr-2013, 05:32 AM.

      Comment

      • johnkors
        Visitor
        • Apr 2013
        • 4

        #4
        The title says "Text Merge", and 3 files are showing in the Beyond Compare UI like what I'm used to from a 3-way merge.

        Comment

        • Aaron
          Team Scooter
          • Oct 2007
          • 15997

          #5
          I notice that the latest stable release of Git is currently 1.8.2.2. Is updating Git an option? We have seen odd Git behavior in the past, and updating usually helps.

          I notice you edited the command line. Did it have the exact same path to the exact same file 4 times?

          BC3 is opening in the Text Merge session because it has been passed 4 file parameters. A diff would normally only pass 2. We would only receive 4 during a Merge (Yours,Theirs,Ancestor, and Output).
          Aaron P Scooter Software

          Comment

          • johnkors
            Visitor
            • Apr 2013
            • 4

            #6
            Yeah, you are probably right. Tried with these two versions, since I had both installed on another computer.

            Cmd prompt : git version 1.7.11.msysgit.1 => opens text compare correctly
            Git Shell (GitHub for Windows) : git version 1.8.0.msysgit.0 => opens text merge

            Will try to update git. Thanks!

            Comment

            • geekgirl
              New User
              • Aug 2015
              • 1

              #7
              I'm dredging this thread up as I've run into the same problem with git version 1.9.5.github.0 in Windows 8.1. I was able to get it to work by editing my C:\users\<username>\.gitconfig file so it now looks like the following. Now the git difftool <filename> command works like it should.

              [diff]
              tool = bc3
              [difftool "bc3"]
              cmd = 'C:/Program Files (x86)/Beyond Compare 3/BComp.exe' \"$LOCAL\" \"$REMOTE\"

              Comment

              • Aaron
                Team Scooter
                • Oct 2007
                • 15997

                #8
                Hello,

                That is pretty close to our current recommended configuration:
                http://www.scootersoftware.com/suppo...vcs#gitwindows

                And the GitHub directions we have here:
                http://www.scootersoftware.com/suppo...#githubwindows

                Glad that configuration was able to work with your current setup.
                Aaron P Scooter Software

                Comment

                Working...