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

Re: Git destroys u+s and g+s directory modes

From
GGGabor Gombas <gombasgg@gmail.com>
Date
Dec 27, 2025, 21:49 UTC
Message-ID
<aVBUg289AKC0HIVx@lan>
In-Reply-To
<74793560-49ae-494e-afff-9b833dd25d1c@danisch.de>
On Sat, Dec 27, 2025 at 03:40:11PM +0100, Hadmut Danisch wrote:
Show 5 quoted lines
> This does not solve the problem, since ACLs do not propagate into newly
> created subdirectories, as group ownership with S_ISGID flag does.
> 
> 
> Please try to understand the problem before trying to solve it.

Well, default ACLs may very well be the solution to your problem, because git does not understand ACLs, so it would leave them alone. Of coure, managing ACLs at scale have their fair share of problems, so YMMV. The problem with the permission bits is git trying to be clever and thinking it can manage them - but as often, trying to be clever ends up not being clever at all. Unfortunately, there does not seem to be a configuration option to tell git to leave permission bits alone. core.filemode is the closest one, but what you want is the opposite behavior - what you want is not ignoring the executable bit, but ignoring everything _except_ the executable bit. Maybe you can try to make a patch...

Regards, Gabor

Previous: Andreas SchwabNext: Hadmut Danisch
Message 7 of 9 in “Git destroys u+s and g+s directory modes”
  1. Hadmut DanischDec 27, 2025
  2. Michal SuchánekDec 27, 2025
  3. rsbecker@nexbridge.comDec 27, 2025
  4. Hadmut DanischDec 27, 2025
  5. rsbecker@nexbridge.comDec 27, 2025
  6. Andreas SchwabDec 27, 2025
  7. Gabor GombasDec 27, 2025
  8. Hadmut DanischDec 27, 2025
  9. Jeff KingJan 2, 2026

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.