Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Tan <jonathantanmy@google.com>2021-08-17 00:09:52 +0300
committerJunio C Hamano <gitster@pobox.com>2021-09-08 21:47:49 +0300
commit8d33c3af0b2113091ea2c2c94990d0332c9551e7 (patch)
tree5bffcf5ca31a4cdedb6bb0c562d4ed16600ed24e /submodule.h
parenta35e03dee0e8daa442227018ecd180ae1c1b39bc (diff)
grep: use submodule-ODB-as-alternate lazy-addition
In the parent commit, Git was taught to add submodule ODBs as alternates lazily, but grep does not use this because it computes the path to add directly, not going through add_submodule_odb(). Add an equivalent to add_submodule_odb() that takes the exact ODB path and teach grep to use it. Signed-off-by: Jonathan Tan <jonathantanmy@google.com> Reviewed-by: Emily Shaffer <emilyshaffer@google.com> Reviewed-by: Matheus Tavares <matheus.bernardino@usp.br> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'submodule.h')
-rw-r--r--submodule.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/submodule.h b/submodule.h
index c252784bc2..17a06cc43b 100644
--- a/submodule.h
+++ b/submodule.h
@@ -104,6 +104,7 @@ int bad_to_remove_submodule(const char *path, unsigned flags);
* the_repository.
*/
int add_submodule_odb(const char *path);
+void add_submodule_odb_by_path(const char *path);
int register_all_submodule_odb_as_alternates(void);
/*