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

Re: [PATCH] init: don't reset core.filemode on git-new-workdirs.

From
Junio C Hamano <gitster@pobox.com>
Date
Mar 23, 2021, 20:50 UTC
Message-ID
<xmqqr1k51tnd.fsf@gitster.g>
In-Reply-To
<20210323203124.oxzqad2wmedelstu@tb-raspi4>
Torsten Bögershausen <tboegi@web.de> writes:
Show 8 quoted lines
>> I do not think we want to go there.  filemode is not the only thing
>> that would be shared.  What do you want to do with core.eol=native,
>> for example?  Paths touched while switching branches get the 'native'
>> line endings on the system that the user happened to be on when the
>> "switch" command was run, and working tree files end up with mixture?
>
> I don't intend to solve all possible confusions caused by sharing all
> config variables - just this very one.

I intend to help users by drawing a clear red line and telling them that crossing that line leads them to danger.

Sharing a working tree across systems that require different core.* settings (filemode included) is on the other side of that line, and that is the reason why I said I do not think we want to go there. By saying "this is only about core.filemode but you can share a working tree between incompatible systems", I am afraid that we end up training users to go where they should not get nearby.

Previous: Torsten BögershausenNext: Madhu
Message 12 of 13 in “init: don't reset core.filemode on git-new-workdirs.”
  1. init: don't reset core.filemode on git-new-workdirs.Madhu, Mar 21, 2021
  2. Junio C HamanoMar 21, 2021
  3. MadhuMar 22, 2021
  4. Junio C HamanoMar 22, 2021
  5. MadhuMar 22, 2021
  6. Junio C HamanoMar 22, 2021
  7. MadhuMar 23, 2021
  8. Junio C HamanoMar 23, 2021
  9. Torsten BögershausenMar 23, 2021
  10. Junio C HamanoMar 23, 2021
  11. Torsten BögershausenMar 23, 2021
  12. Junio C HamanoMar 23, 2021
  13. MadhuJun 18, 2021

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.