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

Re: [PATCH 1/1] repo-settings: read an int for index.version

From
Philip Oakley <philipoakley@iee.email>
Date
Oct 24, 2019, 11:04 UTC
Message-ID
<e32c2694-e86c-0b93-a680-36b367f4258e@iee.email>
In-Reply-To
<095b43f606a352527c9e0551adbd8a6af2061176.1571863137.git.gitgitgadget@gmail.com>
spelling nit.
On 23/10/2019 21:38, Derrick Stolee via GitGitGadget wrote:
Show 10 quoted lines
> From: Derrick Stolee<dstolee@microsoft.com>
>
> Several config options were combined into a repo_settings struct in
> ds/feature-macros, including a move of the "index.version" config
> setting in 7211b9e (repo-settings: consolidate some config settings,
> 2019-08-13).
>
> Unfortunately, that file looked like a lot of boilerplate and what is
> clearly a factor of copy-paste overload, the config setting is parsed
> with repo_config_ge_bool() instead of repo_config_get_int(). This means
s/_ge_bool()/_get_bool()/
Show 14 quoted lines
> that a setting "index.version=4" would not register correctly and would
> revert to the default version of 3.
>
> I caught this while incorporating v2.24.0-rc0 into the VFS for Git
> codebase, where we really care that the index is in version 4.
>
> This was not caught by the codebase because the version checks placed
> in t1600-index.sh did not test the "basic" scenario enough. Here, we
> modify the test to include these normal settings to not be overridden by
> features.manyFiles or GIT_INDEX_VERSION. While the "default" version is
> 3, this is demoted to version 2 in do_write_index() when not necessary.
>
> Signed-off-by: Derrick Stolee<dstolee@microsoft.com>
> ---
Philip
Previous: Derrick Stolee via GitGitGadget
Message 3 of 3 in “[v2.24.0-rc0 BUG] index.version is not parsed correctly”
  1. 0/1 [v2.24.0-rc0 BUG] index.version is not parsed correctlyDerrick Stolee via GitGitGadget, Oct 23, 2019
  2. 1/1 repo-settings: read an int for index.versionDerrick Stolee via GitGitGadget, Oct 23, 2019
  3. Philip OakleyOct 24, 2019

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.