diff options
-rw-r--r-- | config.c | 2 | ||||
-rw-r--r-- | config.h | 1 | ||||
-rw-r--r-- | submodule-config.c | 4 |
3 files changed, 6 insertions, 1 deletions
@@ -3311,6 +3311,8 @@ const char *config_scope_name(enum config_scope scope) return "worktree"; case CONFIG_SCOPE_COMMAND: return "command"; + case CONFIG_SCOPE_SUBMODULE: + return "submodule"; default: return "unknown"; } @@ -42,6 +42,7 @@ enum config_scope { CONFIG_SCOPE_LOCAL, CONFIG_SCOPE_WORKTREE, CONFIG_SCOPE_COMMAND, + CONFIG_SCOPE_SUBMODULE, }; const char *config_scope_name(enum config_scope scope); diff --git a/submodule-config.c b/submodule-config.c index 85064810b2..b8e97d8ae8 100644 --- a/submodule-config.c +++ b/submodule-config.c @@ -635,7 +635,9 @@ static void submodule_cache_check_init(struct repository *repo) static void config_from_gitmodules(config_fn_t fn, struct repository *repo, void *data) { if (repo->worktree) { - struct git_config_source config_source = { 0 }; + struct git_config_source config_source = { + 0, .scope = CONFIG_SCOPE_SUBMODULE + }; const struct config_options opts = { 0 }; struct object_id oid; char *file; |