Visual Studio 2015 using Git failed to compare files

I wanted to run diff in a file in my project, which should be a simple task, and when I select Compare with Unmodified, I get an error:

Source Control - Git Failed to start the configured comparison tool.

I looked at the .gitconfig file that VS2015 automatically generated, and as far as I can tell, there is nothing wrong with that.

[merge] tool = vsdiffmerge [diff] tool = vsdiffmerge [core] editor = \"C:/Program Files (x86)/GitExtensions/GitExtensions.exe\" fileeditor autocrlf = true [credential] [filter "lfs"] clean = git-lfs clean %f smudge = git-lfs smudge %f required = true [difftool] prompt = false [difftool "vsdiffmerge"] cmd = \"C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\Common7\\IDE\\vsdiffmerge.exe\" \"$LOCAL\" \"$REMOTE\" //t [difftool "vsdiffmerge"] keepbackup = false [mergetool] prompt = false [mergetool "vsdiffmerge"] cmd = \"C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\Common7\\IDE\\vsdiffmerge.exe\" \"$REMOTE\" \"$LOCAL\" \"$BASE\" \"$MERGED\" //m trustexitcode = true 

Any thoughts?

+2
source share
2 answers

Uninstall all versions of Git on the machine and reinstall the version you need. It seemed to work for me.

+2
source

If reinstalling Git does not help, there is another solution that I found for a specific case.

If your project is under a subdirectory of the main Git repository directory, which has its own Git repository, deleting the repository in the subdirectory will fix the problem. This may be the case if you previously had a Git repository and decided that you needed a different repository that had a larger scope than just the project you were working on and did not delete the old Git repository files.

+1
source

Source: https://habr.com/ru/post/1236989/


All Articles