Kevin:

>> > The release repository is readable by all members of the project group,
>> > but only writeable by the release manager.  That individual only pushes
>> > vetted patches into the release repository.
>> >
>> > In this dev/release scenario, if the patches exist on the same
>> > machine/filesystem, a get/pull/push will usually result in hard-links
>> > to the same file.  However, owner, group, and permissions for a
>> > hard-linked file are global to all links, so it's impossible to have
>> > different settings for patches shared by both repositories unless
>> > --nolinks is used to ensure that each repository has its own copy of
>> > the patch.

I don't get it.  Darcs never modifies a patch file in place; what it
does is create a new one and update the index.  Since neither the
directory nor the index file are shared by linking, I don't see how
there can be any issues in your example.

The only case of lossage I can see is if

  1. Alice has read permissions on Bob's repository, so she pulls from there;
     The two repos being on the same filesystem, the patch files are linked.
  2. Bob decides he no longer loves Alice, so he chmod -r's his repo.

In that case, Alice ends up with a repository that points at files
that she no longer has the right to read.  Of course, it's her fault
for annoying Bob in the first place.

(Note by the way that there is an interesting related issue.  Suppose
that Bob runs out of disk quota, and decides to rm -r his repository.
Since Alice still has links to the files, the file data will be
retained, and while Bob will no longer hold any links to said files,
he'll still be paying for them.  What a lovely way for Alice to get even.)

Eric:

> Also, would it be possible for darcs simply to detect those cases, and
> not create the links in those cases?

The issue here is that Darcs linked files at a time when they were
readable by Alice, but Bob changed the permissions later on.  Contrary
to popular belief, lazy evaluation is not implemented using premonition,
and Darcs has no way of knowing that Bob will dump Alice for Chloe
(Damian's former girlfriend, but Damian is now with Eve) and change
the permissions later on.

                                        Juliusz
_______________________________________________
darcs-devel mailing list
[email protected]
http://lists.osuosl.org/mailman/listinfo/darcs-devel

Reply via email to