1

I'm trying to migrate a very large svn repository and initially I just started a fetch from revision 13989.

This gave me the chance of having an uptodate git mirror which was awesome - but it took weeks to create.

Now I would like to get the full history in there (i.e. r1-13989) and tried doing:

svn git fetch -r 0:13989

(as described in Git svn clone: How to defer fetch of revision history)

This seemed to work (it was fetching for 3 days) but the files that before had their history abruptly end at 13989 before still has this abrupt end.

The new fetched revisions are not aligned into the history.

Any way to fix this other than having to start doing a full complete giv svn init/fetch again ?

4

1 に答える 1

0

Git コミット ID は、そのコンテンツのハッシュです。親IDを含むメタデータを含めます。したがって、特定のコミットの履歴を変更することはできません。

Git には、親を偽ってコミットするメカニズムがあります。「移植」といいます。(正確な詳細は覚えていません。ドキュメントで調べてください)。自動共有はセキュリティ上の問題になるため、ローカルのみです。

filter-branchまた、コマンドという履歴全体を書き換えるメカニズムも備えています。これにより、以前にグラフトとして指定した親を持つ新しいコミット ID を持つ新しい履歴が作成されます。永久に git に切り替えていて、subversion へのコミットをやめる場合は、先に進んで filter-branch してグラフトを適用できます。ただし、追加のメタデータがあるため、操作後に git-svn が機能するかどうか (または修正方法) はわかりません。

于 2012-09-25T08:36:43.463 に答える