From 48de315817281e49a5e9000d40550b5257b437c6 Mon Sep 17 00:00:00 2001 From: Christian Couder Date: Tue, 25 Jun 2019 15:40:27 +0200 Subject: Add initial support for many promisor remotes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The promisor-remote.{c,h} files will contain functions to manage many promisor remotes. We expect that there will not be a lot of promisor remotes, so it is ok to use a simple linked list to manage them. Helped-by: Jeff King Helped-by: SZEDER Gábor Signed-off-by: Christian Couder Signed-off-by: Junio C Hamano --- promisor-remote.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 promisor-remote.h (limited to 'promisor-remote.h') diff --git a/promisor-remote.h b/promisor-remote.h new file mode 100644 index 0000000000..01dcdf4dc7 --- /dev/null +++ b/promisor-remote.h @@ -0,0 +1,16 @@ +#ifndef PROMISOR_REMOTE_H +#define PROMISOR_REMOTE_H + +/* + * Promisor remote linked list + * Its information come from remote.XXX config entries. + */ +struct promisor_remote { + struct promisor_remote *next; + const char name[FLEX_ARRAY]; +}; + +extern struct promisor_remote *promisor_remote_find(const char *remote_name); +extern int has_promisor_remote(void); + +#endif /* PROMISOR_REMOTE_H */ -- cgit v1.2.3