Note that there are some explanatory texts on larger screens.

plurals
  1. POCommand-line access to VS 2012 merge tool
    text
    copied!<p>I am investigating using TFS 2012 as the Source Control provider for Matlab, on Windows 7. This requires installing the VS 2012 shell/TFS client, and the 64-bit MSSCCI provider available as free downloads from Microsoft. I've set all this up and it works OK.</p> <p>However, there is a problem with file differencing and merging. If I view differences from VS 2012 Source Control Explorer, the VS 2012 Diff tool runs correctly. If I try the same operation from within Matlab (using the Source Control menu) I get an error "Cannot Execute the Configured Tool". The same thing happens with the 'merge changes in merge tool' button when resolving conflicts: in VS 2012 it works, from Matlab, it doesn't.</p> <p>It appears this is a known problem, at least with other tools trying to drive TFS. There is a work-around, which is to configure VS 2012 to use an external differencing utilty. I tried this and it worked. Furthermore, I found that if you configure the external differencing utility to be VS 2012's own 'internal' diff tool, the internal tool will be correctly called from Matlab.</p> <p>The diff command is:</p> <pre><code>C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\devenv.exe </code></pre> <p>and the required arguments are:</p> <pre><code> /Diff %1 %2 %6 %7 </code></pre> <p>(i.e. original file, modified file, original file label, modified file label). There is documentation on this <a href="http://msdn.microsoft.com/en-us/library/vstudio/jj874068.aspx" rel="nofollow">here</a>.</p> <p>The merge tool is more problematic. I can't find any specific documentation on its command line. The closest I've got so far is</p> <pre><code>C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\vsDiffMerge.exe </code></pre> <p>which I'm pretty certain is right, but the arguments I'm using</p> <pre><code>%1 %2 %1 %2 %3 %4 /m </code></pre> <p>are not quite right - the file labels are different, and the difference display is formatted differently (from the normal built-in tool). I reverse-engineered this command line from some git-related documentation <a href="http://social.technet.microsoft.com/wiki/contents/articles/17905.conflitti-durante-lo-sviluppo-concorrente-it-it.aspx" rel="nofollow">here</a> but I don't know anything about git, nor do I speak Italian. Can anybody help me find the correct command line options to use, please?</p> <p><strong>EDIT TO ADD</strong></p> <p>There is an MSDN Discussion which seems to be related to this problem <a href="http://visualstudiogallery.msdn.microsoft.com/b1ef7eb2-e084-4cb8-9bc7-06c3bad9148f/view/Discussions" rel="nofollow">here</a>. It looks like it happens with other tools and is not limited to Matlab: I've re-tagged this question accordingly</p> <p><strong>EDIT TO ADD</strong></p> <p>The preferred command-line for the Diff functionality is:</p> <pre><code>C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\IDE\vsDiffMerge.exe </code></pre> <p>and the command-line arguments are:</p> <pre><code>/t %1 %2 %6 %7 </code></pre> <p>The equivalent for the Merge functionality does not work: this is an internal bug &amp; Microsoft have acknowledged this.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload