如果执行了 svn cp 而不是 cp,是否可以追溯添加历史记录? [英] Is it possible to retroactively add history that would have been there if an svn cp had been performed instead of a cp?

查看:30
本文介绍了如果执行了 svn cp 而不是 cp,是否可以追溯添加历史记录?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个包含一个目录的项目,该目录最初(数百次提交前)是从另一个目录逐字复制的,但是没有使用 svn cp,因此历史上存在脱节.现在可以在初始复制点连接这两个目录,还是来不及了?

I have a project with one directory that was originally (several hundred commits ago) copied verbatim from another directory, but svn cp wasn't used so there's a disconnect in history. Is it possible to connect the two directories at the initial copy point now, or is it too late?

推荐答案

让我猜猜你在说什么:

  • 目录 foo 在 Subversion 中
  • 在修订版 #100 中,有人将 foo 复制到 bar
  • 然后他们将 bar 添加到存储库并提交并创建了修订版 #101.
  • 现在 Subversion 的修订版为 #2302.
  • Directory foo is in Subversion
  • In revision #100, someone copied foo to bar
  • They then added bar to the repository and did a commit and created revision #101.
  • Now Subversion is at revision #2302.

你想要做的是以某种方式回到历史上回到修订版#100,重做副本并添加一个真正的svn copy.这样,你就可以看到 bar 从 foo 复制的历史记录.

What you want to do is somehow go back in history back to revision #100, and redo the copy and add with a true svn copy. That way, you can see the history of bar that it was copied from foo.

可能有一种方法可以对存储库进行 svnadmin 转储,然后进行 svnadmin 加载.

There might be a way of doing an svnadmin dump of the repository, and then an svnadmin load.

您需要创建一个版本 1 到 100 的转储和另一个 102 的转储到头.您将修订版 1 到 100 加载到存储库中.然后你做你的 svn copy 并提交修订版 101.最后,你加载修订版 102 以进入存储库.

You need to create a dump of revisions 1 to 100 and another dump of 102 to head. You load in revisions 1 to 100 into the repository. Then you do your svn copy and commit revision 101. Finally, you load in revisions 102 to head into the repository.

理论上,这应该可以解决问题.我从来没有做过这个特别的修复,但我做过其他选择性的转储和加载,我改变了历史.

That, in theory, should fix the issue. I have never done this particular fix, but I've done other selective dump and loads where I changed the history.

这篇关于如果执行了 svn cp 而不是 cp,是否可以追溯添加历史记录?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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