user6934519
user6934519

Reputation:

Migrate SVN to GitHub with Selected Branches

I want to migrate a project from SVN to GitHub.

The structure of the SVN project is:

Project URL
    trunk
        application1
        application2
        application3
    branches
        version1.0
            application1
            application2
            application3
        version2.0
            application1
            application2
            application3
        version3.0
            application1
            application2
            application3
        version4.0
            application1
            application2
            application3

What I want to have on GitHub is four folders:

application1
    master 
    version1.0
    version2.0
    version3.0
    version4.0
application2
    master 
    version1.0
    version2.0
    version3.0
    version4.0
application3
    master 
    version1.0
    version2.0
    version3.0
    version4.0
application4
    master 
    version1.0
    version2.0
    version3.0
    version4.0

I tried using the command (for one application):

git svn clone --username $username  --trunk=trunk/application1                  
      --branches=braches/version1/application1    --branches=braches/version2/application1   --branches=braches/version3/application1  
--branches=braches/version4/application1 
 --authors-file=authors_modified.txt  $svnURL   application1    --no-metadata`

But I got the error

W: Ignoring error from SVN, path probably does not exist: (160013): 
Filesystem has no item: File not found: revision 100, path '/branches'
W: Do not be alarmed at the above message git-svn
 is just searching aggressively for old history.

If this migration is feasible, if yes, what's wrong here?

Upvotes: 0

Views: 68

Answers (1)

Lazy Badger
Lazy Badger

Reputation: 97280

  1. Convert your complex tree with SubGit, not git-svn
  2. Perform conversion per application in a time, not in one huge step

Upvotes: 1

Related Questions