return platform_core_config(var, value, ctx, cb);
}
-static int git_default_sparse_config(const char *var, const char *value)
-{
- if (!strcmp(var, "sparse.expectfilesoutsideofpatterns")) {
- sparse_expect_files_outside_of_patterns = git_config_bool(var, value);
- return 0;
- }
-
- /* Add other config variables here and to Documentation/config/sparse.adoc. */
- return 0;
-}
-
static int git_default_i18n_config(const char *var, const char *value)
{
if (!strcmp(var, "i18n.commitencoding")) {
return 0;
}
- if (starts_with(var, "sparse."))
- return git_default_sparse_config(var, value);
-
/* Add other config variables here and to Documentation/config.adoc. */
return 0;
}
#endif
enum object_creation_mode object_creation_mode = OBJECT_CREATION_MODE;
int grafts_keep_true_parents;
-int sparse_expect_files_outside_of_patterns;
int merge_log_config = -1;
int precomposed_unicode = -1; /* see probe_utf8_pathname_composition() */
unsigned long pack_size_limit_cfg;
extern int protect_hfs;
extern int protect_ntfs;
-extern int sparse_expect_files_outside_of_patterns;
-
enum rebase_setup_type {
AUTOREBASE_NEVER = 0,
AUTOREBASE_LOCAL,
-#define USE_THE_REPOSITORY_VARIABLE
#define DISABLE_SIGN_COMPARE_WARNINGS
#include "git-compat-util.h"
void clear_skip_worktree_from_present_files(struct index_state *istate)
{
+ int sparse_expect_files_outside_of_patterns = 0;
+ repo_config_get_bool(istate->repo, "sparse.expectfilesoutsideofpatterns",
+ &sparse_expect_files_outside_of_patterns);
if (!istate->repo->settings.sparse_checkout ||
sparse_expect_files_outside_of_patterns)
return;