On Thu, Apr 21, 2016 at 1:11 AM, Eric Sunshine wrote:
> On Wed, Apr 20, 2016 at 9:24 AM, Nguyễn Thái Ngọc Duy
> wrote:
>> diff --git a/path.c b/path.c
>> @@ -503,6 +503,35 @@ void strbuf_git_path_submodule(struct strbuf *buf,
>> const char *path,
>> +const char *git_common_path(const char *fmt,
On Wed, Apr 20, 2016 at 9:24 AM, Nguyễn Thái Ngọc Duy wrote:
> diff --git a/path.c b/path.c
> @@ -503,6 +503,35 @@ void strbuf_git_path_submodule(struct strbuf *buf, const
> char *path,
> +const char *git_common_path(const char *fmt, ...)
> +{
> + struct strbuf *pathname = get_pathname();
>
These are mostly convenient functions to reduce code duplication. Most
of the time, we should be able to get by with git_path() which handles
$GIT_COMMON_DIR internally. However there are a few cases where we need
to construct paths manually, for example some paths from a specific
worktree. These f
3 matches
Mail list logo