[darcs-devel] [issue643] darcs get does not get email pref

Matt Palmer matt at solutionsfirst.com.au
Mon Feb 4 00:54:18 UTC 2008


On Mon, Feb 04, 2008 at 12:23:53AM -0000, Ben Coburn wrote:
> Darcs "get" does not download the "_darcs/prefs/email" preference. Maybe I'm
> misunderstanding the manual here, but this behavior seems wrong. IMHO, the
> default email for darcs "send" should follow the repository around like the
> "defaultrepo" preference.

I disagree.  Since the 'email' pref is retrieved from the remote repo when
you say "I want to send to this remote repo", having the email pref follow
you around would result in things like this:

echo "foo at bar.com" > trunk/_darcs/prefs/email
darcs get trunk local
darcs get local work
cd work
<do stuff>
darcs send
<darcs looks at local's email pref, and sends the patch to trunk's e-mail
address>

Which means that the patch ends up in trunk, and not in local, which isn't
what's expected.  What's more, repeated sends will say "ooh, I need to send
this patch" when it'll just get ignored by the actual repo that the patch is
being applied to because it's already been applied.

The current behaviour ultimately makes a lot more sense, IMO.  This is even
despite that fact that I use multi-level repos like you're proposing, to
allow me to do a darcs send while offline (or make it quicker when I'm
online) -- I have a local 'trunk' that is a replica of the main upstream
repo, with the upstream's e-mail address in the 'email' pref.  Despite it's
utility, I don't think it should be the default behaviour, because it
requires a lot more thought on my part to track where patches are and need
to be moved to.  Making it the default would just confuse people.

- Matt


More information about the darcs-devel mailing list