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

Re: [PATCH 0/4] environment: move line ending config variables into repo_config_values

From
Patrick Steinhardt <ps@pks.im>
Date
Oct 26, 2026, 12:27 UTC
Message-ID
<at9HOXZhVcl53CGX@pks.im>
In-Reply-To
<20261024220012.486-1-aniketgupta3001@gmail.com>
Hi,
On Sat, Oct 24, 2026 at 10:00:08PM +0000, Aniket Gupta wrote:
Show 13 quoted lines
> Hi,
> 
> This series moves the global variables behind core.autocrlf, core.eol
> and core.safecrlf into 'struct repo_config_values' to continue the
> libification effort.
> 
> The first patch passes 'repo' to the working tree conversion
> functions which need it to read the values. The other three move one
> variable each just like the earlier conversions.
> 
> An alternative to passing 'repo' would be to store the resolved values
> in 'struct conv_attrs'. I went with passing it since that is what the
> earlier conversions did, but I can change it if you prefer.

This isn't really your fault, but we've had the discussion multiple times by now that we need to stop moving more config values into `repo_config_values` until we have a way for how to decouple it from `the_repository`. The problem here is that the only way to populate those settings is via `repo_config(git_default_config)`, and that function will populate the repo config values of `the_repository`. Consequently, `repo_config_values()` BUGs when called with a different repostiory.

While these patches _look_ like they libify Git more, they actually do the exact opposite right now and tie us more and more to `the_repository`. So I'm inclined to say that we should hold off merging these patches until we fix that issue, or otherwise we paint ourselves into a corner.

Patrick
Previous: Aniket GuptaNext: Aniket Gupta
Message 6 of 11 in “environment: move line ending config variables into repo_config_values”
  1. 0/4 environment: move line ending config variables into repo_config_valuesAniket Gupta, Oct 24, 2026
  2. 1/4 convert: pass 'repo' to the working tree conversion functionsAniket Gupta, Oct 24, 2026
  3. 2/4 environment: move auto_crlf into repo_config_valuesAniket Gupta, Oct 24, 2026
  4. 3/4 environment: move core_eol into repo_config_valuesAniket Gupta, Oct 24, 2026
  5. 4/4 environment: move global_conv_flags_eol into repo_config_valuesAniket Gupta, Oct 24, 2026
  6. Patrick SteinhardtOct 26, 2026
  7. Aniket GuptaOct 26, 2026
  8. Patrick SteinhardtOct 26, 2026
  9. Junio C HamanoOct 26, 2026
  10. Patrick SteinhardtNov 3, 2026
  11. Junio C HamanoNov 3, 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.