开发者

TFS overwrite all files that are identical

I have installed开发者_开发知识库 TFS 2010 for the first time - checked everything in on the dev box, I am now mapping everything on the build machine but I have 11,000+ conflicts saying a writable file by the same name exists on the local machine.

What I want to do is an overwrite of the local file, but only if the TFS version is the same. TFS should know this because if I do a compare it tells me if there are any differences. Is there a way to do this without having to click each one individually?


TFS won't do that, sorry.

I detest TFS for providing a decent UI but a backend that behaves like a bad knockoff of SVN.


You can do this but it will take a few steps - and I would strongly advise that you not do this more than once (i.e., if you are planning for this process to be part of your build you need to look for another process). This is not how TFS is meant to be used. If you want to edit files in a TFS workspace you need to check the files out first.

First move all your existing files out of the workspace - this is your master copy.

Next do a force get from TFS into the now empty workspace folder.

Now install the latest TFS 2010 power tools from MSDN.

You know how some options. What I would do is use Beyond Compare or another tool to diff the master and workspace content and resolve all the conflicts by copying from the master to the workspace. Another option would be to just xcopy the master content over the workspace but I prefer Beyond Compare because you can manually copy every change and be confident with the changes.

What you now have is a workspace with your master changes overlaid on to it.

Now use the "tfpt.exe online" command from the workspace root. It will go off and find the delta between the workspace and what you've put in to it and pended the changes.

You can now check those changes in.


I do not know if there is a way to do this.

The issue is that for the sake of performance TFS is not doing a file comparison against each file, it is checking its records for that file in that workspace and seeing if it has already downloaded the up to date file.

You can however use tf resolve to resolve all of the conflicts since it sounds like the build machine is more up to date then source control.


If you just checked-in files and then checked-out them - they should be identical and fell free to overwrite them.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜