如何回退签入Clearcase的文件? [英] How do I roll back a file checked in to Clearcase?

查看:170
本文介绍了如何回退签入Clearcase的文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的Clearcase存储库中有一个文件。我将其签出并对其进行了修改,然后又将其签回。

I have a file in my Clearcase repository. I checked it out and modified it, and then checked it back in.

我还没有做过任何事情,例如创建基准,重新设置基准,或在流中/

I haven't done anything like make a baseline, or rebase, or deliver in my stream/view.

很遗憾对此文件进行了更改-回想起来,我本应撤消结帐。

I regret having made the changes to this file--I should have undone the checkout, in retrospect.

如何回滚修改? (或撤消或还原,或使用任何正确的术语。)

How do I roll back the modifications? (Or undo, or revert, or whatever the correct nomenclature is.)

推荐答案

描述内容 skwllsp 可以在动态视图通过使用扩展路径名

cd m:/myDynamicView/MyVob/path/to/file
cleartool lsvtree myFile
cleartool checkout -c "cancel co" myFile
copy myFile@@/main/xx myFile
cleartool checkin -nc myFile

带有 xx 是您要还原的版本号。

with xx being the version number you want to restore.

但是,如果您已进行多次 签入,包括您要取消的签入,ClearCase允许您通过 减法合并

请参阅IBM 以删除某些版本的内容(和 合并手册页

But should you have made multiple checkins, including some you want to cancel, ClearCase allows you to cancel part of the previous checkins through Subtractive Merge
See IBM "to remove contributions of some versions" (and merge man page)


您可以一次删除一系列版本中的所有更改。例如,以下命令在主分支上删除版本14到16的修订:

You can remove all changes from a range of versions at once. For example, the following command removes revisions to versions 14 through 16 on the main branch:


  • 在UNIX系统或Linux上:



cleartool merge -graphical -to opt.c -delete -version /main/14 /main/16





  • 在Windows系统上:



cleartool merge -graphical -to opt.c -delete -version \main\14 \main\16




您还可以一次从一个版本中删除更改。例如,以下命令仅从签出当前视图的opt.c版本中删除版本14中的更改:

You can also remove the changes from one version at a time. For example, the following commands remove only the changes in version 14 from the version of opt.c checked out the current view:


  • 在UNIX系统或Linux:



cleartool merge -graphical -to opt.c -delete -version /main/14





  • 在Windows系统上:



cleartool merge -graphical -to opt.c -delete -version \main\14




或者,在上述任何示例中,如果您使用供稿人版本选择器的版本扩展路径,则可以省略-version参数。

Alternatively, in any of the examples above, you can leave out the -version argument if you use the version extended path for the contributor-version-selector.






最后,不要做的一件事是 rmver

此命令会无可挽回地破坏信息,这很少是一件好事。


Finally, the one thing to not do is a rmver.
This command destroys information irretrievably and this is rarely a good thing.

这篇关于如何回退签入Clearcase的文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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