Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Junio C Hamano
Ramsay Jones writes: >> +git checkout -b mode initial && >> +git update-index --chmod=+x file0 && > > would 'test_chmod +x file0 &&' work here? This one wants to set +x only in the index, leaving the working tree version without the executable bit.

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Jeff King
On Wed, Sep 27, 2017 at 04:57:40PM -0700, Stefan Beller wrote: > >> + GIT_AUTHOR_DATE="2006-06-26 00:06:00 +" && > >> + GIT_COMMITTER_DATE="2006-06-26 00:06:00 +" && > >> + export GIT_AUTHOR_DATE GIT_COMMITTER_DATE && > >> + git checkout -b mode initial && > >> + git

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Jeff King
On Wed, Sep 27, 2017 at 03:51:26PM -0700, Stefan Beller wrote: > In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, > 2017-06-29), the conversion from direct printing to the symbol emission > dropped the new line character for renamed, copied and rewritten files. > > Add

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Stefan Beller
>> + GIT_AUTHOR_DATE="2006-06-26 00:06:00 +" && >> + GIT_COMMITTER_DATE="2006-06-26 00:06:00 +" && >> + export GIT_AUTHOR_DATE GIT_COMMITTER_DATE && >> + git checkout -b mode initial && >> + git update-index --chmod=+x file0 && > > would 'test_chmod +x file0 &&' work

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Ramsay Jones
On 27/09/17 23:51, Stefan Beller wrote: > In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, > 2017-06-29), the conversion from direct printing to the symbol emission > dropped the new line character for renamed, copied and rewritten files. > > Add the emission of a

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Jonathan Nieder
Stefan Beller wrote: > In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, > 2017-06-29), the conversion from direct printing to the symbol emission > dropped the new line character for renamed, copied and rewritten files. > > Add the emission of a newline, add a test for

[PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Stefan Beller
In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, 2017-06-29), the conversion from direct printing to the symbol emission dropped the new line character for renamed, copied and rewritten files. Add the emission of a newline, add a test for this case. Reported-by: Linus

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Jeff King
On Wed, Sep 27, 2017 at 03:39:00PM -0700, Stefan Beller wrote: > On Wed, Sep 27, 2017 at 3:32 PM, Jeff King wrote: > > > The most appropriate place seems like t4013. I tried adding to its big > > list of tested formats, but it's quite fragile. The patch below is what > > I came

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Stefan Beller
On Wed, Sep 27, 2017 at 3:32 PM, Jeff King wrote: > The most appropriate place seems like t4013. I tried adding to its big > list of tested formats, but it's quite fragile. The patch below is what > I came up with, but it still needs updated to cover the cases which call > "log

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Stefan Beller
On Wed, Sep 27, 2017 at 3:09 PM, Jeff King wrote: > On Wed, Sep 27, 2017 at 02:58:52PM -0700, Stefan Beller wrote: > >> From: Linus Torvalds >> >> In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, >> 2017-06-29), the

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Jeff King
On Wed, Sep 27, 2017 at 06:09:25PM -0400, Jeff King wrote: > > diff --git a/t/t4016-diff-quote.sh b/t/t4016-diff-quote.sh > > index 9c48e5c2c9..514056dd10 100755 > > --- a/t/t4016-diff-quote.sh > > +++ b/t/t4016-diff-quote.sh > > @@ -30,6 +30,7 @@ test_expect_success setup ' > > git add . &&

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Jeff King
On Wed, Sep 27, 2017 at 02:58:52PM -0700, Stefan Beller wrote: > From: Linus Torvalds > > In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, > 2017-06-29), the conversion from direct printing to the symbol emission > dropped the new line

Re: [PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Linus Torvalds
On Wed, Sep 27, 2017 at 2:58 PM, Stefan Beller wrote: > > Linus, I assumed your sign off for the original patch. Thanks for spotting. > > Adding the mode change to t4016 seems like the easiest way to test it. Looks good to me, and you don't need to give me authorship

[PATCH] diff: correct newline in summary for renamed files

2017-09-27 Thread Stefan Beller
From: Linus Torvalds In 146fdb0dfe (diff.c: emit_diff_symbol learns about DIFF_SYMBOL_SUMMARY, 2017-06-29), the conversion from direct printing to the symbol emission dropped the new line character for renamed, copied and rewritten files. Add the emission of a