如何在 Visual Studio TFS 中回滚? [英] How to rollback in Visual Studio TFS?

查看:12
本文介绍了如何在 Visual Studio TFS 中回滚?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在处理一个使用 VSTS 2008 的大型项目的一个子模块.

I'm working on one sub-module of a large project for which is use VSTS 2008.

我需要将模块回滚到早期版本(之前大约有 4 次签入).我尝试在 Visual Studio UI 中执行此操作,最终意识到没有回滚选项.

I have a need to rollback the module to an earlier version (about 4 check-ins previous). I tried to do this in the Visual Studio UI, and finally realized there is no option to rollback.

经过一些研究,我确定有一个强大的工具下载,声称支持通过命令行工具进行回滚.但是,似乎几乎没有相关文档.

After some research, I determined there is a power tools download that purports to support rollback via a command-line tool. However, there appears to be virtually no documentation for it.

谁能一步一步地描述如何在 VS2008 中回滚到以前的版本?(使用电动工具或其他方式).

Can anyone describe step by step how to rollback to a previous version in VS2008? (Using Power Tools or otherwise).

额外问题——有谁知道我们是否会在 VS2010 中获得更强大的回滚支持?

Bonus question--anyone know if we might get more robust rollback support in VS2010?

推荐答案

右键单击源代码管理资源管理器中的文件夹.选择获取特定版本.选择您想要获取的版本(按变更集、日期、标签等).

Right-click on the folder in Source Control Explorer. Choose Get Specific Version. Choose the version that you want to get (by changeset, date, label, etc).

此时您的本地版本将是您想要的版本.检出更改过的文件,然后将它们重新检入.这将调出合并向导,并且它可能会抱怨服务器的版本比您更新的如何.通过向导并按照您希望的方式合并文件(其中一个选项是放弃服务器更改,这听起来像是您想要的).在此过程结束时,它可能会告诉您由于合并过程(或类似性质)没有签入任何文件,只需点击确定",然后再次签入.这应该可以满足您的需求.

At this point your local version will be the version that you want. Check out the changed files and then check them back in. This will bring up the merge wizard and it will probably be complaining about how the server has a newer version than you do. Go through the wizard and merge the files the way you want them (one of the options is to discard the server changes, which is what it sounds like you want). At the end of this process, it may tell you that no files were checked in due to the merge process (or something of that nature), just hit OK and then check in again. This should accomplish what you need.

这篇关于如何在 Visual Studio TFS 中回滚?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆