TFS 回滚 vs “获取此版本" [英] TFS Rollback vs "Get This Version"

查看:33
本文介绍了TFS 回滚 vs “获取此版本"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

回滚和获取此版本"有什么区别?

What is the difference between Rollback and "Get This Version" ?

他们都让我回到特定版本,然后从那里进行更改和签入.

Both of them let me go back to a specific version and from there doing changes and check-in.

两者兼有的额外好处是什么?

What are the additional benefits of having both of them?

推荐答案

获取特定版本/获取此版本

仅影响您的本地工作区,它将所有本地更改还原为旧版本.当您尝试检查这些更改时,您将遇到合并冲突,并且需要解决这些问题.例如,当您需要调试旧版本的应用程序时,它很有用.签入并强制合并本地版本不会删除任何添加的文件,并且可能会造成相当大的混乱.另外,不清楚您做了什么,因为所有更改都只会显示为编辑或添加.获取特定版本也不会还原任何合并票证,因此以后的合并可能会导致意外行为.

Only effects your local workspace, it reverts all your local changes to an older version. When you try to check these changes in, you'll get a merge conflict and will need to resolve these issues. It's useful when you need to debug an older version of your application for example. Checking in and forcing the local version on merge will not delete any files that were added and can cause quite a bit of mayhem. Plus, it's unclear what you've done, as all the changes will just show up as edit or add. Get specific version also doesn't revert any merge tickets, thus later merges can result in unexpected behaviors.

回滚

为选定的更改创建补偿签入.它只会回滚所选变更集中的更改(并且可以回滚历史记录中的任意变更集).它将此更改附加为具有特殊回滚"类型的新更改集.因此,从历史记录中可以清楚地看出,您返回并恢复了之前的一些更改.回滚将通过删除文件来正确补偿添加,并通过重新添加文件来正确补偿删除.回滚合并时,合并票也会被还原,确保在您稍后尝试合并分支时重新评估这些更改.

Creates a compensating checkin for the selected changes. It will rollback only the changes in the selected changesets (and can roll back an arbitrary changeset in the history). It appends this change as a new changeset with the special "rollback" type. So it's clear from the history that you went back and reverted some previous changes. A rollback will correctly compensate an add by deleting the file and a delete by adding it back in. When rolling back a merge, the merge tickets also get reverted, ensuring that these changes are reevaluated when you try to merge branches later.

这篇关于TFS 回滚 vs “获取此版本"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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