Pabs TheGeek
Pabs TheGeek

Reputation: 9

svn to git migration with long history is over 6Gb

I've been tasked with migrating our SVN to Git, while I've managed to do some projects there is one project that is giving me trouble.

Having converted this project, the Git repo is over 6Gb. Note I have removed all binaries for SVN before the migration.

This project has over 1000 tags and 100 branches, and within the .git folder the svn folder is @4.9Gb not sure what I can do. I don't want to lose history, but I can not see how to reduce this folder.

Upvotes: 0

Views: 191

Answers (2)

bahrep
bahrep

Reputation: 30662

over 1000 tags and 100 branches

Branching and tagging is cheap in SVN and in git and should not cause your repository to be 4-6GB. There have to be other data that's taking up the space. Or the project you work with is large by itself.

The problem is that you expect git repository to be (much) smaller that SVN repository. This is a common mistake. SVN and git repository with the same dataset will be about the same size and git repository can be even larger in certain cases.

SVN solves this problem by providing you with disposable working copies that are fast to checkout. However, as you must clone a whole repository with git, you will have to divide your single monorepo into multiple smaller repositories.

Upvotes: 0

VonC
VonC

Reputation: 1325966

In addition of my old answer, which is for one Git repo, you could consider having *multiple Git repos.

That is: doing the SVN migration of a sub-folder of the SVN repo (to one Git repo)

That way, you end up with a collection of Git repos more manageable in size, which can be interesting if you don't need the all content in order to develop.

Upvotes: 1

Related Questions