Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Jacob Keller
On Thu, Aug 18, 2016 at 12:04 PM, Stefan Beller wrote: > On Wed, Aug 17, 2016 at 5:51 PM, Jacob Keller > wrote: >> + if (is_null_sha1(one)) >> + message = "(new submodule)"; >> + else if (is_null_sha1(two)) >> +

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Stefan Beller
On Thu, Aug 18, 2016 at 1:24 PM, Jacob Keller wrote: > On Thu, Aug 18, 2016 at 12:04 PM, Stefan Beller wrote: >> On Wed, Aug 17, 2016 at 5:51 PM, Jacob Keller >> wrote: >>> + if (is_null_sha1(one)) >>> +

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Stefan Beller
On Wed, Aug 17, 2016 at 5:51 PM, Jacob Keller wrote: > From: Jacob Keller > > A future patch is going to add a new submodule diff format which > displays an inline diff of the submodule changes. To make this easier, > and to ensure that both

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Jacob Keller
On Thu, Aug 18, 2016 at 1:49 PM, Junio C Hamano wrote: > Jacob Keller writes: > > If we were to change those, we could discuss if we want to go with > full sentences > all the time: > > submodule is new > submodule is

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Junio C Hamano
Jacob Keller writes: If we were to change those, we could discuss if we want to go with full sentences all the time: submodule is new submodule is deleted submodule is not initialized >>> >>> I agree, I'll make a new patch

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Jacob Keller
On Thu, Aug 18, 2016 at 1:39 PM, Stefan Beller wrote: > On Thu, Aug 18, 2016 at 1:24 PM, Jacob Keller wrote: >> On Thu, Aug 18, 2016 at 12:04 PM, Stefan Beller wrote: >>> On Wed, Aug 17, 2016 at 5:51 PM, Jacob Keller

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread Jacob Keller
On Thu, Aug 18, 2016 at 12:00 AM, David Aguilar wrote: >> +void show_submodule_summary(FILE *f, const char *path, >> + const char *line_prefix, >> + unsigned char one[20], unsigned char two[20], >> + unsigned dirty_submodule, const char *meta,

Re: [PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-18 Thread David Aguilar
On Wed, Aug 17, 2016 at 05:51:30PM -0700, Jacob Keller wrote: > [snip] > @@ -333,31 +326,23 @@ static void print_submodule_summary(struct rev_info > *rev, FILE *f, > strbuf_release(); > } > > -void show_submodule_summary(FILE *f, const char *path, > +/* Helper function to display the

[PATCH v7 6/7] submodule: refactor show_submodule_summary with helper function

2016-08-17 Thread Jacob Keller
From: Jacob Keller A future patch is going to add a new submodule diff format which displays an inline diff of the submodule changes. To make this easier, and to ensure that both submodule diff formats use the same initial header, factor out show_submodule_header()