Re: confused about preserved permissions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mike Hommey <mh@xxxxxxxxxxxx> writes:

> On Mon, Aug 20, 2007 at 06:44:11PM +0200, martin f krafft <madduck@xxxxxxxxxxx> wrote:
>> Why does git bother saving a mode when later it never seems to use
>> it again?
>
> Same applies to git-archive, which generates files with mode 666 and
> directories with 777, while it could follow the modes in the
> repository... or at least, that's what the manpage claims, but facts
> seem to be quite different...

Git had permissions at one point of time.  It makes colloboration with
other people with different umasks a nuisance.  However, not all uses
are colloborative.  So it might be nice to be able to specify
permission/uid/gid policies that do a configurable level of munging
for stuff passed into and out of the index and/or the repositories.

> I also never understood why there were no permissions set on
> directories in trees...

Because directories are not actually tracked.  They are created and
deleted as-needed.

In my proposal for allowing directories to get tracked, permissions of
000 would indicate a tree without a corresponding tracked directory.
Other permissions would correspond to a tracked directory.  I am still
stuck over the representation in the index.

One idea is to unconditionally have an entry "dirname" without
permissions, and optionally "dirname/" with permissions iff the
directory is supposed to be tracked, both to be sorted in
alphabetically.  The idea of the first entry is being able to detect
merge conflicts without extra passes.

But I have not worked on the stuff for a while.

> nor why, while the sha1 for child objects are "packed", the modes
> aren't...

Because a change of the mode of a file will then not cause different
sha1 sums at the file level.

-- 
David Kastrup

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux