Re: [PATCH v1 2/8] Add a function to update HEAD after creating a commit

2017-11-07 Thread Phillip Wood
On 07/11/17 03:02, Johannes Schindelin wrote: > Hi Junio, > > On Tue, 7 Nov 2017, Junio C Hamano wrote: > >> Phillip Wood writes: >> >>> @@ -751,6 +751,42 @@ int template_untouched(const struct strbuf *sb, const >>> char *template_file, >>> return

Re: [PATCH v1 2/8] Add a function to update HEAD after creating a commit

2017-11-07 Thread Johannes Schindelin
Hi Junio, On Tue, 7 Nov 2017, Junio C Hamano wrote: > Phillip Wood writes: > > > @@ -751,6 +751,42 @@ int template_untouched(const struct strbuf *sb, const > > char *template_file, > > return rest_is_empty(sb, start - sb->buf); > > } > > > > +int

Re: [PATCH v1 2/8] Add a function to update HEAD after creating a commit

2017-11-06 Thread Junio C Hamano
Phillip Wood writes: > @@ -1735,25 +1733,10 @@ int cmd_commit(int argc, const char **argv, const > char *prefix) > strbuf_release(_ident); > free_commit_extra_headers(extra); > > - nl = strchr(sb.buf, '\n'); > - if (nl) > -

[PATCH v1 2/8] Add a function to update HEAD after creating a commit

2017-11-06 Thread Phillip Wood
From: Phillip Wood Add update_head() based on the code that updates HEAD after committing in builtin/commit.c that can be called by 'git commit' and other commands. Signed-off-by: Phillip Wood --- builtin/commit.c | 19