Hg 转换失去分支
我正在尝试转换 Mercurial 存储库,将所有文件移动到一个子目录中,准备将两个存储库合并为一个。我遇到的问题是我的一些分支在转换过程中丢失了。
这就是我正在做的事情:
hg convert --filemap filemap.txt SourceRepo DestRepo
我的 filemap.txt 如下:
rename . subdir
当此命令完成时,DestRepo 丢失了已创建但未对其进行任何更改的 SourceRepo 的所有分支。
我之所以拥有与父级完全相同的分支,是因为原始存储库是 SVN 存储库,所以我们使用分支来标记版本。
有什么方法可以在不丢失分支的情况下完成此转换?
编辑:回答 Ry4n 的问题。
源存储库是一个 Mercurial 存储库,它是使用 hgsubversion 扩展从 SVN 存储库创建的。
这是分支的日志:
> hg log -b V3.02.55
changeset: 84:cf19dfac555c
branch: V3.02.55
parent: 71:aec56bf6ad9a
user: steve.kaye@868e8ea5-81c6-0a4c-a81c-ce52fb006997
date: Wed Aug 24 15:31:01 2011 +0000
summary: Branching V3.02.55
I'm trying to convert a Mercurial repository to move all the files into a subdirectory in preparation for merging two repositories into one. The problem that I am having is that some of my branches are being lost in the conversion process.
This is what I am doing:
hg convert --filemap filemap.txt SourceRepo DestRepo
My filemap.txt is as follows:
rename . subdir
When this command completes, DestRepo is missing all branches of SourceRepo that were created but which had no changes made to them.
The reason why I have branches that are exactly the same as the parent is because the original repository was an SVN repository so we used branches to tag versions.
Is there any way that I can complete this conversion without losing the branches?
EDIT: Answering Ry4n's question.
The source repo is a Mercurial repository which was created from an SVN repository using the hgsubversion extension.
Here is a log of the branch:
> hg log -b V3.02.55
changeset: 84:cf19dfac555c
branch: V3.02.55
parent: 71:aec56bf6ad9a
user: steve.kaye@868e8ea5-81c6-0a4c-a81c-ce52fb006997
date: Wed Aug 24 15:31:01 2011 +0000
summary: Branching V3.02.55
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在 Mercurial 中,不存在没有任何更改的命名分支之类的东西。如果您的源存储库是 Mercurial 存储库,它要么没有这些命名分支,要么至少有一项更改。
您的源是 Mercurial 吗?
如果是这样,您能否为您认为存在但没有更改的分支之一提供
hg log -b NAME
输出?In Mercurial there is no such thing as a named branch with no changes on them. If your source repo is a Mercurial repository it either doesn't have those named branches or they have at least one change on them.
Is your source Mercurial?
If so, Can you provide the
hg log -b NAME
output for one of the branches you think exists but has no changes?