From: Junio C Hamano Date: Sat, 17 Jan 2026 18:37:34 +0000 (-0800) Subject: Merge branch 'ob/core-attributesfile-in-repository' into seen X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e3ca2323f94346494ebecc847234d79221b1c7e9;p=thirdparty%2Fgit.git Merge branch 'ob/core-attributesfile-in-repository' into seen The core.attributesfile is intended to be set per repository, but were kept track of by a single global variable in-core, which has been corrected by moving it to per-repository data structure. Comments? * ob/core-attributesfile-in-repository: environment: move "branch.autoSetupMerge" into `struct repo_config_values` environment: environment: stop using core.sparseCheckout globally environment: stop storing `core.attributesFile` globally --- e3ca2323f94346494ebecc847234d79221b1c7e9 diff --cc environment.c index 0026eb2274,437d14e1ae..b5fa2c99a6 --- a/environment.c +++ b/environment.c @@@ -301,9 -321,11 +298,11 @@@ next_name return (current & ~negative) | positive; } -static int git_default_core_config(const char *var, const char *value, - const struct config_context *ctx, void *cb) +int git_default_core_config(const char *var, const char *value, + const struct config_context *ctx, void *cb) { + struct repo_config_values *cfg = &the_repository->config_values; + /* This needs a better name */ if (!strcmp(var, "core.filemode")) { trust_executable_bit = git_config_bool(var, value); diff --cc environment.h index 27f657af04,bfcdffe836..489fd62053 --- a/environment.h +++ b/environment.h @@@ -106,9 -117,9 +117,11 @@@ const char *strip_namespace(const char int git_default_config(const char *, const char *, const struct config_context *, void *); +int git_default_core_config(const char *var, const char *value, + const struct config_context *ctx, void *cb); + void repo_config_values_init(struct repo_config_values *cfg); + /* * TODO: All the below state either explicitly or implicitly relies on * `the_repository`. We should eventually get rid of these and make the