是的,我知道hg-fast-export.sh which some people really hate
即使我最终设法让它找到mercurial模块,它仍然不能用于我的回购:
$ $HOME/Notes/fast-export/hg-fast-export.sh -r $HOME/path-to-repo
Error: repository has at least one unnamed head: hg r194
git-fast-import statistics:
. . .
在目标git仓库中不产生任何东西。
我在git repo中尝试了hg-to-git:
$HOME/Desktop/tmp/git-master/contrib/hg-to-git/hg-to-git.py -v .
tip is 1197
analysing the branches...
Traceback (most recent call last):
File "/Users/dsw/Desktop/tmp/git-master/contrib/hg-to-git/hg-to-git.py", line 135, in <module>
hgchildren[parent] += ( str(cset), )
KeyError: '-1'
也许这是hg-to-git试图告诉我hg-fast-export告诉我的同样的事情,只是以更加内心和格式的方式。不知怎的,我认为一个工具应该在奇怪的情况下继续前进,并产生至少部分结果,即使它告诉用户这个问题。
有人有任何建议吗?