aboutsummaryrefslogtreecommitdiffstats
path: root/path.h
diff options
context:
space:
mode:
Diffstat (limited to 'path.h')
-rw-r--r--path.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/path.h b/path.h
index ea96487b29..a6f0b70692 100644
--- a/path.h
+++ b/path.h
@@ -4,6 +4,7 @@
struct repository;
struct strbuf;
struct string_list;
+struct worktree;
/*
* The result to all functions which return statically allocated memory may be
@@ -82,6 +83,14 @@ const char *git_path(const char *fmt, ...)
__attribute__((format (printf, 1, 2)));
/*
+ * Similar to git_path() but can produce paths for a specified
+ * worktree instead of current one
+ */
+const char *worktree_git_path(const struct worktree *wt,
+ const char *fmt, ...)
+ __attribute__((format (printf, 2, 3)));
+
+/*
* Return a path into the main repository's (the_repository) git directory.
*/
char *git_pathdup(const char *fmt, ...)
@@ -173,7 +182,6 @@ const char *git_path_fetch_head(struct repository *r);
const char *git_path_shallow(struct repository *r);
int ends_with_path_components(const char *path, const char *components);
-int validate_headref(const char *ref);
int calc_shared_perm(int mode);
int adjust_shared_perm(const char *path);