0

My goal was to migrate svn to git and keep trunk and some directly diverged branch/A, plus their merge history. Additionally syncing between git and svn was required.

I already managed to create single branches in git for trunk and branch/A. Individual commit history for each of them is also there and syncing works. Reference to achieve this: https://gist.github.com/sillage/b1e83eae1249ad1ab0dc

Now my problem is that both have their independent history with no information when trunk got merged into branch/A. I only see the initial diverge of branch/A from trunk but not any merges from trunk into branch/A later on, which where done in svn.

Is there any chance to mirror these missing merges in my git repository?

EDIT: I would like to reflect the merges done in svn in the mirrored branches in git. So if svn/trunk@commit42 was merged into svn/branch/A@commit43 I would like to reflect it in git. This should result in a connection from git/trunk@commit42 to git/branch/A@commit43.

3
  • 1
    This question is similar to: Can git-svn correctly populate svn:mergeinfo properties?. If you believe it’s different, please edit the question, make it clear how it’s different and/or how the answers on that question are not helpful for your problem.
    – Friedrich
    Commented Mar 18 at 10:55
  • I saw that post, but was not sure if it still up-to-date. I would like to reflect the svn merge history in my git repository. Commented Mar 18 at 11:03
  • 2
    This is bad idea to migrate from svn to git relying on the their compatibility. You can not translate everything from one to another without losing the details. Better to drop the svn and start from the last revision in the git. If you need to lookup the merge info, then just keep use the svn. Another issue here is that git will drop the svn command: github.com/git-for-windows/git/issues/5405
    – Andry
    Commented Mar 18 at 18:20

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.