Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Version control with the least disk-space overhead

I've been considering using a version control system like SVN as a general-purpose backup and synchronisation tool between the few PCs I use. This would be for all sorts of data, including MP3s and ripped DVDs - a LOT of data (120gb+).

My main issue is that SVN creates a copy of each versioned file in the .svn directory. While I can see that this is very useful in most cases, it's entirely unnecessary for my purposes, and a massive waste of disk space.

Is there a VCS which doesn't create a duplicate of the files in your working copy?

Edit to clarify: I'm just talking about the size of the required files on each computer. For SVN, that'd mean the size of the working copy and its meta files - for a DVCS, that'd be the size of the WC and the repository.

like image 239
nickf Avatar asked Jan 19 '09 02:01

nickf


2 Answers

Git is extremely thrifty when it comes to disk space.

The Git vs SVN Comparison Wiki states:

Git's repository and working directory sizes are extremely small when compared to SVN.

For example the Mozilla repository is reported to be almost 12 GiB when stored in SVN using the fsfs backend. The fsfs backend also requires over 240,000 files in one directory to record all 240,000 commits made over the 10 year project history. The exact same history is stored in Git by only two files totaling just over 420 MiB. SVN requires 30x the disk space to store the same history.

An SVN working directory always contains two copies of each file: one for the user to actually work with and another hidden in .svn/ to aid operations such as status, diff and commit. In contrast a Git working directory requires only one small index file that stores about 100 bytes of data per tracked file. On projects with a large number of files this can be a substantial difference in the disk space required per working copy.

like image 103
mmcdole Avatar answered Oct 14 '22 04:10

mmcdole


I think you need to ask a more specific question to get the proper answer for what you are trying to do. You don't actually want a Version Control system, but a digital asset management system.

http://en.wikipedia.org/wiki/Digital_asset_management

Does that sound better?

like image 43
Xedecimal Avatar answered Oct 14 '22 04:10

Xedecimal