Reputation: 3715
Does anyone know if there is a way to check if code from production hotfix branch is not newer than mainstream branch via diff tool of some sort? (hotfix1 vs thrunk)
\src
\thrunk
\releases
\hotfix1
I'm using vs2010 with TFS, but the branches have a lot of files, and all I came up with was comparing one file at a time, by re-specifying the target path of one of them.
Upvotes: 39
Views: 41260
Reputation: 27009
In Visual Studio, in the menu bar select:
NOTE: Notice all the different options you have on this screen.
Upvotes: 16
Reputation: 9004
You can do it easily from Visual Studio, but if you are like me and don't want to mess you local branch, you can also do it from the VSTS Website
it is not as difficult as it sounds, :)
Upvotes: 0
Reputation: 1062
You can merge one branch into the other without committing. Then you can see all the changes in visual studio. When you're done you just have to reset all the changes (if you don't want to merge).
Upvotes: 2
Reputation: 1433
Using the "Compare" function as mentioned previously is great, but having good filters makes it way more useful. Otherwise you can get overloaded with huge amounts of info.
Here are the filters I am currently using which work very well for me:
!debug\;!obj\;!bin\;!temp\;!*ReSharper*\;*.sln;*.*proj;*.config;*.cs;*.vb;*.bmp;*.GIF;*.JPG;*.png;*.ico;*.ini;*.resx;
The first few items eliminate some folders you probably want to exclude (debug, obj, bin, temp, Resharper stuff if you are using it - and it is highly recommended that you do!). The rest are the files that I find useful to include in the search. If there are other file types you want to see, just add them to the end of the list.
Upvotes: 5
Reputation: 945
actually you dont have to be in the same workspace to do compares from VS - or even both in TFS. 1 or both could be in the file system ("Local Path..." in "Compare" dlg) or in TFS ("Server Path..."). THe "Filter" section is very powerful as well, to be able to expand/restrict the comparison objects by file type.
Upvotes: 0
Reputation: 78673
You can do this from right within Visual Studio - if you open Team Explorer and go to Source Control, you can compare folders recursively (even ones you don't have in your workspace.) Simply navigate to one of the branches, right click and select Compare
and enter the other branch as the target.
Upvotes: 161
Reputation: 108995
Using the command line tool tf.exe
you can compare two revisions of arbitrary files, but both have to be in your workspace.
See online help on tf diff
for details (and here for specifying versions).
NB. In VS use Tools | Options | Source Control | Visual Studio Team Foundation Server | Configure User Tools to define what diff/merge application to use (a web search will find the right command line to use). Entering .*
for the file type will be used for everything without a more specific tool set.
Upvotes: 5