Proposal: inherit group

Adrian Buehlmann adrian at cadifra.com
Thu Oct 11 03:09:54 CDT 2012


On 2012-10-11 09:42, Isaac Jurado wrote:
> On Thu, Oct 11, 2012 at 3:57 AM, Matt Mackall <mpm at selenic.com> wrote:
>> Currently, Mercurial inherits file permission bits from .hg/store. This
>> lets newly-created files in a repo on a shared filesystem get
>> group-compatible permissions regardless of the current umask of the
>> user.
>>
>> Unfortunately, the group attached to the file will not automatically be
>> a useful one unless all the directories in .hg/store are also carefully
>> marked g+s so that newly-created files and directories get shared with
>> the appropriate group. This, being a bit outside Unix Permissions 101,
>> is apparently not something most people know how to do.
>>
>> So it might significantly ease things if we tried to automatically copy
>> the group from the .hg/store directory to newly created files and
>> directories in the store.
> 
> What about ACL enabled Unices or the Windows equivalent?  Is there an
> intention to support that?  I'm not using either one, but I believe
> that sooner or later someone will come up with the question.

I don't think that the answer to this question is a blocking one [1]
with regards to Windows.

I believe on Windows, everything is "inherit" from the parent dir by
default anyway - regarding permissions when creating subdirs and files.
As long as we don't interfere with that, we should be fine on Windows.

So I think we can safely ignore Windows for now while pondering Matt's
proposal.

[1] in the sense that we need to have the answer in order to implement
    Matt's proposal


More information about the Mercurial-devel mailing list