git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Does git have "Path-Based Authorization"?

From
GGrant <emailgrant@gmail.com>
Date
Oct 1, 2011, 01:43 UTC
Message-ID
<CAN0CFw1-Edb5PdoTzJz38vJOjjXVAg6F24XgHpTi+3e5C7yxfQ@mail.gmail.com>
In-Reply-To
<CACsJy8Dm-vSoki9Fr7s=DH7oRYL-a=kF7q9mBwo55ZxsLg5DTA@mail.gmail.com>
Show 11 quoted lines
>> I have a series of files containing server-side code which make up a
>> website.  The entire layout contains only a few folders, but those
>> folders contain many files.  I want to be able to allow access to only
>> certain files at a time, sometimes only a single file.  Can that be
>> done in the way you describe?
>
> If you can gather all sensitive files in a subdirectory, then you can
> split that directory into its own repository (see git-submodule man
> page) and grant limited access to that repo.
> --
> Duy

I thought about separating files the dev has had access to into a separate folder from files the dev hasn't had access to, but it would mean constantly changing the code as files move around, plus it would be too complicated if I have multiple devs and want to give them access to different stuff. It's not that some files are more sensitive than others, it's just that I don't want to give anyone access to more than I have to.

- Grant
Previous: Nguyen Thai Ngoc DuyNext: david@lang.hm
Message 5 of 15 in “Does git have "Path-Based Authorization"?”
  1. GrantSep 30, 2011
  2. Carlos Martín NietoOct 1, 2011
  3. GrantOct 1, 2011
  4. Nguyen Thai Ngoc DuyOct 1, 2011
  5. GrantOct 1, 2011
  6. david@lang.hmOct 1, 2011
  7. Jakub NarebskiOct 1, 2011
  8. GrantOct 2, 2011
  9. Sitaram ChamartyOct 2, 2011
  10. GrantOct 2, 2011
  11. Nguyen Thai Ngoc DuyOct 2, 2011
  12. GrantOct 2, 2011
  13. Andreas KreyOct 2, 2011
  14. Frans KlaverOct 2, 2011
  15. Enrico WeigeltOct 2, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.