[darcs-users] peer to peer darcs

David Roundy droundy at abridgegame.org
Sat Jul 31 10:15:43 UTC 2004


On Fri, Jul 30, 2004 at 04:26:07PM -0400, Andrew Pimlott wrote:
> On Fri, Jul 30, 2004 at 03:12:09PM -0400, S. Alexander Jacobson wrote:
> > On Fri, 30 Jul 2004, David Roundy wrote:
> > > The order in which patches are received wouldn't be a problem unless they
> > > get a patch bundle before they have its context,
> 
> Isn't the obvious partial solution to this to send out patches with a
> minimal context, instead of the full context as now?  Or maybe it should
> send both, and give apply a --force option to use the minimal context.
> My understanding is that the context in a send is the intersection
> between the two repositories.  This is conservative, but generally much
> more than is needed.

I'm not sure I know what you mean by minimal.  It seems to me that the
minimal context would be no context, and you'd be sending then entire
repo... since this doesn't make any sense, I think you must mean something
else, but I'm not sure what... :)

Oh, I get it.  You could commute the patches into a minimal context, yes,
that would be very clever (and I even thought about doing something like
this at one time).  This would be a nice feature.  The only problem is that
it could be very slow, O(n^2) in the worst case sceneario, in which half
the patches in the repo are in the minimal context.  Specifying a tag to
keep in the context would greatly alleviate the slowness problem, but would
perhaps over-complicate the feature.  I guess something like

darcs send --to me at work --to-tag 0.9.23 --minimal-context

I'm not sure whether --to-tag would be appropriate, meaning I'm sending to
a person who I know has version 0.9.23, or --from-tag, meaning push changes
since 0.9.23.

Also note, that the O(n^2) will happen on patch bundle application as well
as the creation.
-- 
David Roundy
http://www.abridgegame.org




More information about the darcs-users mailing list