All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Lehmann <Jens.Lehmann@web.de>
To: redhat1981 <redhat1981@gmail.com>
Cc: "Magnus Bäck" <magnus.back@sonyericsson.com>, git@vger.kernel.org
Subject: Re: Folder level Acces in git
Date: Thu, 03 Nov 2011 19:13:17 +0100	[thread overview]
Message-ID: <4EB2D9BD.6020801@web.de> (raw)
In-Reply-To: <20111103071701.GA22412@jpl.local>

Am 03.11.2011 08:17, schrieb Magnus Bäck:
> On Thursday, November 03, 2011 at 07:10 CET,
>      redhat1981 <redhat1981@gmail.com> wrote:
>> Inside the repository, testabc let us say there are folders folder1,
>> folder 2 etc, I want some users to have read/write, read or no access
>> to the folder1 or folder2, Is this possible in Git, I have done it in
>> SVN, Please help!!
> 
> Given Git's nature, you can't have read access restrictions on a sub-git
> level (i.e. file/directory level). For basically the same reason, you
> can never prevent users from making (local) commits that modify certain
> paths (but you can encourage people to have local hooks to enforce such
> policies). What you *can* do is install a server-side update hook that
> rejects attempts to push commits that modify certain paths. If you're
> willing to trade Gitosis for Gitolite, you get that feature for free.

Directory read access control can be achieved by putting the directory
content into a submodule. You can then control who is allowed to clone
from the repo for that submodule separately from the superproject,
thereby disallowing a group of people to see (let alone modify) what is
in there.

http://progit.org/book/ch6-6.html

  reply	other threads:[~2011-11-03 18:13 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-03  6:10 Folder level Acces in git redhat1981
2011-11-03  7:17 ` Magnus Bäck
2011-11-03 18:13   ` Jens Lehmann [this message]
2011-11-03 19:28 ` Eugene Sajine
2011-11-04  4:21   ` Joshua Jensen
2011-11-04  8:42     ` Jens Lehmann
2011-11-04 15:59     ` Eugene Sajine

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EB2D9BD.6020801@web.de \
    --to=jens.lehmann@web.de \
    --cc=git@vger.kernel.org \
    --cc=magnus.back@sonyericsson.com \
    --cc=redhat1981@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.