13

Problem: The default diff/ merge tool in visual studio 2015 (and previous versions) does not allow merging when you compare a file. It only allows you to see differences. The only occasion I'm aware of the 3 way merge option being enabled is when there is a merge conflict.

I want to see the 3 way merge option on every instance of the diff tool in Visual Studio.

Notes: I'm definitely not looking for an alternative tool or a 'work around' on this. I have been happily using WinMerge as my merge tool which allows merging anytime you compare. I really like the vs diff tool's 3 way option and being able to use it any time I want would be a nice boost to my work flow.

Thanks!

TheDev6
  • 882
  • 9
  • 17
  • does this guide helps: https://roadtoalm.com/2013/10/22/use-visual-studio-as-your-diff-and-merging-tool-for-local-files/ – Md. Tazbir Ur Rahman Bhuiyan Oct 09 '17 at 06:30
  • I have moved on to Git and the Git Extensions which has more diff options/ settings. That link does look promising for both vs and git. Did you get it to work for you @Tazbir? – TheDev6 Nov 16 '17 at 23:20
  • I am using vs for git merging and comparing yes. I didn’t went through the link i provided in the earlier comment. U can test out the implementation in a test env such as vm. – Md. Tazbir Ur Rahman Bhuiyan Nov 17 '17 at 01:56

2 Answers2

1

For anyone Googling Winmerge 3 way merging, Visual Studios settings for a merge are as follows: Command: C:\Program Files (x86)\WinMerge\WinMergeU.exe Arguments: /e /u /wl /dl %7 /dm %8 /dr %6 %2 %3 %1 %4

Mark Ball
  • 366
  • 2
  • 10
  • 1
    while it does seem to work , unlike visual studio internal 3 way merge i can't seem to find an option in winmerge that the take the line from each file and put it the result file. (marking checkboxes on both files in visual studio merge) – Hagay Goshen Feb 11 '19 at 08:02
1

The above solution didn't work for me (I used WinMerge 2.16.2). In whatever way I ended the merge, Visual Studio said merge operation was cancelled. Final solution for me was to use /o argument:

/e /x /u /wl /dl %7 /dm %8 /wr /dr %6 %2 %3 %1 /o %4

Configuration is MINE BASE THEIRS /x closes the compare if files are identical /wr makes the right file readonly

Ondrej B
  • 11
  • 1