submodule-config: lazy-load a repository's .gitmodules file
[gitweb.git] / builtin / reset.c
index 046403ed6881f452271c636e935ad3ab05da0b78..772d078b8531a7740652a5f39ad2d4c6ef885004 100644 (file)
@@ -156,6 +156,7 @@ static int read_from_tree(const struct pathspec *pathspec,
        opt.output_format = DIFF_FORMAT_CALLBACK;
        opt.format_callback = update_index_from_diff;
        opt.format_callback_data = &intent_to_add;
+       opt.flags |= DIFF_OPT_OVERRIDE_SUBMODULE_CONFIG;
 
        if (do_diff_cache(tree_oid, &opt))
                return 1;