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

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJameson Miller <jamill@microsoft.com>2014-08-20 18:24:41 +0400
committerJameson Miller <jamill@microsoft.com>2014-09-03 05:07:26 +0400
commitbc737620dd0d331cb80c22d074569fe29b7ab585 (patch)
tree02845048ed92a316433bf6c38d8283408d6b530f /include/git2/repository.h
parent0ee9f31c3b11116ab5806ab80d03b1d37197d6ce (diff)
Introduce option to use relative paths for repository work directory
Teach git_repository_init_ext to use relative paths for the gitlink to the work directory. This is used when creating a sub repository where the sub repository resides in the parent repository's .git directory.
Diffstat (limited to 'include/git2/repository.h')
-rw-r--r--include/git2/repository.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/git2/repository.h b/include/git2/repository.h
index 18e515cb0..268782648 100644
--- a/include/git2/repository.h
+++ b/include/git2/repository.h
@@ -196,6 +196,8 @@ GIT_EXTERN(int) git_repository_init(
* looking the "template_path" from the options if set, or the
* `init.templatedir` global config if not, or falling back on
* "/usr/share/git-core/templates" if it exists.
+ * * GIT_REPOSITORY_INIT_RELATIVE_GITLINK - If an alternate workdir is
+ * specified, use relative paths for the gitdir and core.worktree.
*/
typedef enum {
GIT_REPOSITORY_INIT_BARE = (1u << 0),
@@ -204,6 +206,7 @@ typedef enum {
GIT_REPOSITORY_INIT_MKDIR = (1u << 3),
GIT_REPOSITORY_INIT_MKPATH = (1u << 4),
GIT_REPOSITORY_INIT_EXTERNAL_TEMPLATE = (1u << 5),
+ GIT_REPOSITORY_INIT_RELATIVE_GITLINK = (1u << 6),
} git_repository_init_flag_t;
/**