如何在 Eclipse 中从 CVS 恢复以前的更新

发布于 2024-10-05 21:52:37 字数 233 浏览 7 评论 0原文

我们的项目正在使用CVS,它是从eclipse集成的,因此我们使用Team Synchronizing从CVS获取最新代码,但是是有没有办法从我们已经完成的存储库恢复之前的提交或更新?

我来自git背景,所以我很难从eclipse中找到这个功能/cvs,任何建议都将受到高度赞赏。

Our Project is using CVS and its is integrated from eclipse and so we use Team Synchronizing to get the latest code from CVS but is there a way to revert the previous commit or update from repositry which we have done ?

I come from git background and so I am having hard time to find out this functionality from eclipse/cvs, any suggestion would be highly apprecaited.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

眼眸里的那抹悲凉 2024-10-12 21:52:37

这取决于你所说的“恢复”是什么意思。
git revert 实际上添加了一个新的提交,取消了前一个提交引入的更改。

对于 Eclipse,这将是(逐个文件):“替换为 -> 历史记录
(参见“如何使用 Eclipse 正确回滚到 CVS HEAD 中的旧版本?")

alt text

然后创建一个新提交。
换句话说,似乎没有任何简单的方法来做到这一点(当许多文件受到影响时)......

It depends what you mean by "revert".
The git revert actually add a new commit canceling the changes introduced by the previous one.

With Eclipse, that would be (file by file): "Replace With -> History"
(see "How to properly roll back to an older version in CVS HEAD using Eclipse?")

alt text

And then make a new commit.
In other word, there don't seem to be any simple way to do this (when many files are impacted)...

对你而言 2024-10-12 21:52:37

右键单击该文件->团队->恢复到基地。这将覆盖所有本地更改并恢复为 CVS 中文件的最新版本。

这是你所追求的吗? (我必须承认我觉得这个问题有点不清楚)

Right click on the file -> Team -> Revert to Base. This will overwrite any local changes and revert to the most up-to-date version of the file in CVS.

Any this what you're after? (I have to admit that I find the question somewhat unclear)

往事风中埋 2024-10-12 21:52:37

如果您的意思是取消提交您之前提交的内容,将其从文件历史记录中删除,那么,您不能这样做。

您只能从存储库取回以前的版本并再次提交,并在注释中明确指出您已将文件恢复到以前的版本。

If you mean it in the sense of uncommitting something you committed before, erasing it from the history of the file, then no, you cannot do that.

You can only get the previous version back from the repository and commit that again, making it clear in the comment that you reverted the file to a previous revision.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文