submodule--helper: remove update-module-mode
This is dead code - it has not been used since c51f8f94e5 (submodule--helper: run update procedures from C, 2021-08-24). Signed-off-by: Glen Choo <chooglen@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Glen Choo committed
Mar 4, 2022 at 16:13 UTC
f7bdb3291873f0c10ad63015b18d1caf1ec719d7
1 file changed
-24
builtin/submodule--helper.c
-24
@@ -1957,29 +1957,6 @@ static void determine_submodule_update_strategy(struct repository *r,
1957
free(key);
1958
}
1959
1960
-static int module_update_module_mode(int argc, const char **argv, const char *prefix)
1961
-{
1962
- const char *path, *update = NULL;
1963
- int just_cloned;
1964
- struct submodule_update_strategy update_strategy = { .type = SM_UPDATE_CHECKOUT };
1965
-
1966
- if (argc < 3 || argc > 4)
1967
- die("submodule--helper update-module-clone expects <just-cloned> <path> [<update>]");
1968
-
1969
- just_cloned = git_config_int("just_cloned", argv[1]);
1970
- path = argv[2];
1971
-
1972
- if (argc == 4)
1973
- update = argv[3];
1974
-
1975
- determine_submodule_update_strategy(the_repository,
1976
- just_cloned, path, update,
1977
- &update_strategy);
1978
- fputs(submodule_strategy_to_string(&update_strategy), stdout);
1979
-
1980
- return 0;
1981
-}
1982
-
1960
struct update_clone_data {
1961
const struct submodule *sub;
1962
struct object_id oid;
@@ -3430,7 +3407,6 @@ static struct cmd_struct commands[] = {
3407
{"name", module_name, 0},
3408
{"clone", module_clone, 0},
3409
{"add", module_add, SUPPORT_SUPER_PREFIX},
3433
- {"update-module-mode", module_update_module_mode, 0},
3410
{"update-clone", update_clone, 0},
3411
{"run-update-procedure", run_update_procedure, 0},
3412
{"ensure-core-worktree", ensure_core_worktree, 0},