I have a large binary file which due to integration/automation issues I need to check into subversion. It makes no sense to track past versions of this file. Is there a way I could tell subversion to only store the latest revision and delete past revisions?
Asked
Active
Viewed 104 times
1
-
If this is a batch file, you could simply delete everything but the HEAD of the given file. You know that it does not store full copies of the file right? – Aaron McIver Dec 05 '11 at 22:37
-
Is there a way to do that aside from using svnadmin dump/load? – nash Dec 05 '11 at 23:24
2 Answers
4
There isn't currently any decent way of doing this. You need an svn obliterate
-type function which I believe hasn't been written yet. Several people have written various scripts to achieve similar results, eg Subversion Obliterate feature but the general principle is the same: dump the svn database, pipe through a filter and back into svnadmin load
, which I suspect may be more work than you're looking for.

Community
- 1
- 1

the_mandrill
- 29,792
- 6
- 64
- 93
-
I suspect that your solution is as good as it gets. Not an option for me unfortunately. – nash Dec 05 '11 at 23:21
-
I think your other option is for something more pragmatic, eg instead of checking the binaries into SVN create a consistent naming scheme (eg 'build_13', or '2011-12-06') and copy them over to a file server. You can then manually delete the ones you no longer need. – the_mandrill Dec 06 '11 at 10:00
-
I remember looking into `svn obliterate` a year ago or so, I don't think they're ever going to implement it. – Chris Dec 06 '11 at 19:22
1
Subversion 1.6 also introduced support for external definitions for files. File externals are configured just like externals for directories and appear as a versioned file in the working copy
tells SVNBook
It solves one part of task - don't store future revisions of file, which can be placed outside repo but still be accessible

Lazy Badger
- 94,711
- 9
- 78
- 110