diff options
author | Stefan Beller <sbeller@google.com> | 2016-08-15 14:53:24 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-08-15 15:28:01 -0700 |
commit | 9eeea7d2bc8132cfaa1b79271c077e80317f3ae1 (patch) | |
tree | 311909d3eefff75811402fcaaa95b51549645019 /cache.h | |
parent | submodule--helper update-clone: allow multiple references (diff) | |
download | tgif-9eeea7d2bc8132cfaa1b79271c077e80317f3ae1.tar.xz |
clone: factor out checking for an alternate path
In a later patch we want to determine if a path is suitable as an
alternate from other commands than builtin/clone. Move the checking
functionality of `add_one_reference` to `compute_alternate_path` that is
defined in cache.h.
Signed-off-by: Stefan Beller <sbeller@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'cache.h')
-rw-r--r-- | cache.h | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -1342,6 +1342,7 @@ extern struct alternate_object_database { } *alt_odb_list; extern void prepare_alt_odb(void); extern void read_info_alternates(const char * relative_base, int depth); +extern char *compute_alternate_path(const char *path, struct strbuf *err); extern void add_to_alternates_file(const char *reference); typedef int alt_odb_fn(struct alternate_object_database *, void *); extern int foreach_alt_odb(alt_odb_fn, void*); |