Re: git repository size vs. subversion repository size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2008.04.04 18:02:56 -0400, Sean Brown wrote:
> Last night I decided to see what storage size differences I might see
> between an svn repo and a git one.  So I imported a highly used
> subversion repository into git and was shocked to see how huge the git
> version was.  I used a repo that has a lot of branches and tagged
> releases just to make sure importing into git would in fact keep all
> of the history.  It did keep the history, but the total disk usage was
> very different:
> 
> $subversionbox # du -hs ./my_sample_website/
> 67M	./my_sample_website
> 
> $localhost # du -hs ./git-samplesite/
> 3.6GB ./git-samplesite/

How much of that is in the .git/svn directory? The contents of that
directory are used to map git commits to svn revision and git versions
before 1.5.4 had a quite space consuming file format for that. The new
format is a lot better. If you want to switch completely, you can even
just delete the .git/svn directory, as that's only required as long as
you want to interact with the corresponding svn repository.

And finally, you might want to repack to repository once after the
initial import, to get a smaller repo. Something like:
git repack -a -d -f --window=100 --depth=100

Björn
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux