Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have an svn dump file which includes "empty" revisions (these were created by svnsync when synching only a subdirectory of an existing repository).

Since I'd like to use the svnsync'd repository as the new master (no need to sync again), I wanted to get rid of all the empty revisions.

Unfortunately, running the dump through svndumpfilter does not seem to remove the empty revisions, probably because svndumpfilter only looks at revisions it cleaned up by itself with the --exclude option (see also here)

I was also looking into svndumptool, but it does not seem to provide this functionality.

Is it possible to filter these revisions in any other way?

share|improve this question

this is the command line that i use.. it seems to work pretty well.

svnadmin dump <path_to_repo> | svndumpfilter2 <path_to_repo> [list of paths to keep] --renumber-revs --drop-empty-revs  |bzip2 --best >

the "list of path to keep" can be as simple as trunk

but it does require you to have access to the svn server directly.

share|improve this answer

Okay, I've been hesitant to answer this question, because the solution is not for the faint of heart and could drive you mad.

Try altering the dump file's content manually by removing the revisions which are empty from the dump file. You may also find that you'll need to redo all the sequences of the revision-numbers and double check for copies that the revision being copied from actually exists and/or point it to the correct revision.

Here' the tricky part, be careful editing the dump file. One slip of a extra key could cause a revision to fail from loading as all content is is hashed for check sums.

Good Luck!

share|improve this answer
Yes, I agree that this is not the most suitable way, but it might be the only way since there are no additional answers – Palmin Jan 14 '11 at 11:01

actually i think you need the '-renumber-revs' option from svndumpfilter (or is it svndumpfilter2) in addition to --drop-empty-revs

share|improve this answer
I tried this and it doesn't fix the issue – Palmin Jan 14 '11 at 11:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.