[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] Add '--drop-all-empty-revs' to svndumpfilter include/exclude

From: vijay <vijay_at_collab.net>
Date: Tue, 26 Feb 2013 20:38:41 +0530

On Tuesday 26 February 2013 07:47 PM, Philip Martin wrote:
> vijay <vijay_at_collab.net> writes:
>
>> /* write out the revision */
>> /* Revision is written out in the following cases:
>> - 1. No --drop-empty-revs has been supplied.
>> - 2. --drop-empty-revs has been supplied,
>> - but revision has not all nodes dropped
>> - 3. Revision had no nodes to begin with.
>> + 1. If the revision has nodes or it is revision 0.
>> + 2. --drop-empty-revs has been supplied,
>> + but revision has not all nodes dropped.
>> + 3. No --drop-all-empty-revs has been supplied.
>> + 4. If no --drop-empty-revs or --drop-all-empty-revs have been supplied,
>> + write out the revision which has no nodes to begin with.
>> */
>> - if (rb->has_nodes
>> - || (! rb->pb->drop_empty_revs)
>> - || (! rb->had_dropped_nodes))
>> + if (rb->has_nodes || (rb->rev_orig == 0))
>> + write_out_rev = TRUE;
>> + else if (rb->pb->drop_empty_revs)
>> + write_out_rev = rb->had_dropped_nodes ? FALSE : TRUE;
>> + else if (rb->pb->drop_all_empty_revs)
>> + write_out_rev = FALSE;
>> + else
>> + write_out_rev = TRUE;
>> +
>> + if (write_out_rev)
>> {
>
> You have added the rev_orig == 0 check so that means that
> --drop-all-empty-revs doesn't drop r0. Is there a reason for that
> behaviour?
>

If the dump was taken from a mirror repo, r0 might have some information
like 'svn:sync-from-url', 'svn:sync-from-uuid', etc.
I thought that '--drop-all-empty-revs' should not just drop r0
considering as an empty revision.

Please correct me if I am wrong.

Thanks & Regards,
Vijayaguru
Received on 2013-02-26 16:09:19 CET

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.