summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Han-Wen Nienhuys <hanwen@google.com>2017-09-25 17:59:26 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-09-26 14:08:23 +0900
commit3ce08548bb8768259c98f7fcf30be4c0bae9c611 (patch)
tree4d9b8080026856839e288a1496d5d6d9af1793ec
parentThe ninth batch for 2.15 (diff)
downloadtgif-3ce08548bb8768259c98f7fcf30be4c0bae9c611.tar.xz
submodule.c: describe submodule_to_gitdir() in a new comment
Signed-off-by: Han-Wen Nienhuys <hanwen@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--submodule.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/submodule.c b/submodule.c
index b12600fc79..50bf3fb09c 100644
--- a/submodule.c
+++ b/submodule.c
@@ -1997,6 +1997,10 @@ const char *get_superproject_working_tree(void)
return ret;
}
+/*
+ * Put the gitdir for a submodule (given relative to the main
+ * repository worktree) into `buf`, or return -1 on error.
+ */
int submodule_to_gitdir(struct strbuf *buf, const char *submodule)
{
const struct submodule *sub;