submodule: remove submodule.fetchjobs from submodule-config parsing
The '.gitmodules' file should only contain information pertinent to configuring individual submodules (name to path mapping, URL where to obtain the submodule, etc.) while other configuration like the number of jobs to use when fetching submodules should be a part of the repository's config. Remove the 'submodule.fetchjobs' configuration option from the general submodule-config parsing and instead rely on using the 'config_from_gitmodules()' in order to maintain backwards compatibility with this config being placed in the '.gitmodules' file. Signed-off-by: Brandon Williams <bmwill@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
b22e51cb26
commit
f20e7c1ea2
@ -248,6 +248,14 @@ static int parse_fetch_recurse(const char *opt, const char *arg,
|
||||
}
|
||||
}
|
||||
|
||||
int parse_submodule_fetchjobs(const char *var, const char *value)
|
||||
{
|
||||
int fetchjobs = git_config_int(var, value);
|
||||
if (fetchjobs < 0)
|
||||
die(_("negative values not allowed for submodule.fetchjobs"));
|
||||
return fetchjobs;
|
||||
}
|
||||
|
||||
int parse_fetch_recurse_submodules_arg(const char *opt, const char *arg)
|
||||
{
|
||||
return parse_fetch_recurse(opt, arg, 1);
|
||||
|
Reference in New Issue
Block a user