From: Junio C Hamano Date: Tue, 03 Nov 2026 06:21:14 GMT Subject: Re: [PATCH] environment: move diff_auto_refresh_index into repo_config_values Message-ID: In-Reply-To: "Ebele Lynda Okolo via GitGitGadget" writes: > From: Lynndabel > > The diff_auto_refresh_index variable is currently a global, > which makes it difficult to use Git as a library since > global state can't be isolated between different repository > instances. We do not want to put it in repo_config_value, because access to the structure will barf when given anything other than the_repository, hence such a move does not help the "library" scene very much to begin with. It is only set in diff.c when the ui related configuration variable is read from the git_config() callback. The callback is *not* repository specific but is a synthesized computation result after reading system, global, and repository configuration files, which is another reason why it does not look like a good idea to tie this setting to repo_config_values. Thanks.