Re: [PATCH v1 1/1] git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-03-03 Thread Mike Crowe
Hi Torsten, Your patch has been superseded, but I thought I ought to answer your questions rather than leave them hanging. On Thursday 02 March 2017 at 19:17:00 +0100, Torsten Bögershausen wrote: > On 2017-03-01 22:25, Mike Crowe wrote: > > On Wednesday 01 March 2017 at 18:04:44 +

Re: [PATCH v1 1/1] git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-03-02 Thread Mike Crowe
On Thursday 02 March 2017 at 10:33:59 -0800, Junio C Hamano wrote: > Mike Crowe <m...@mcrowe.com> writes: > > > All the solutions presented so far do cause a small change in behaviour > > when using git diff --quiet: they may now cause warning messages like

git status reports file modified when only line-endings have changed (was git diff --quiet exits with 1 on clean tree with CRLF conversions)

2017-03-02 Thread Mike Crowe
x from https://public-inbox.org/git/xmqqshmyhtnu@gitster.mtv.corp.google.com/T/#m67cbfad1f2efe721f0c2afac2a1523b743bb57ca Here's the test case. Test 3 is the part that currently fails: commit de5f3f1d9161cdd46342689abe38a046fc71850e Author: Mike Crowe <m...@mcrowe.com> Date: Sat Feb 25 09:28:37 2017 +000

Re: [PATCH v1 1/1] git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-03-02 Thread Mike Crowe
lds of filespec > structures to skip content comparison, this bug manifests as a > false "there are differences" for a file that needs eol conversion, > for example. > > Reported-by: Mike Crowe <m...@mcrowe.com> > Helped-by: Torsten Bögershausen <tbo...@web.de>

Re: [PATCH v1 1/1] git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-03-01 Thread Mike Crowe
0. > > Add calls to would_convert_to_git() before blindly saying that a different > size means different content. > > Reported-By: Mike Crowe <m...@mcrowe.com> > Signed-off-by: Torsten Bögershausen <tbo...@web.de> > --- > This is what I can come up with, collecting all t

Re: git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-02-25 Thread Mike Crowe
ot;touch -r .datetime" technique from racy-git.txt but it doesn't help. It seems that I'm unable to stop Git from using its cache without sleeping. :( diff --git a/t/t4063-diff-converted.sh b/t/t4063-diff-converted.sh new file mode 100755 index 000..31a730d --- /dev/null +++ b/t/t4063-

Re: git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-02-20 Thread Mike Crowe
On Friday 17 February 2017 at 22:19:58 +, Mike Crowe wrote: > On Friday 17 February 2017 at 14:05:17 -0800, Junio C Hamano wrote: > > Mike Crowe <m...@mcrowe.com> writes: > > > > > If "git diff --quiet" finds it necessary to compare actual file

Re: git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-02-17 Thread Mike Crowe
On Friday 17 February 2017 at 14:05:17 -0800, Junio C Hamano wrote: > Mike Crowe <m...@mcrowe.com> writes: > > > If "git diff --quiet" finds it necessary to compare actual file contents, > > and a file requires CRLF conversion, then it incorrectly exi

git diff --quiet exits with 1 on clean tree with CRLF conversions

2017-02-17 Thread Mike Crowe
ult = 1; In the failing case p->one->size == 14 and p->two->size == 12. Mike. diff --git a/t/t4063-diff-converted.sh b/t/t4063-diff-converted.sh new file mode 100755 index 000..a108dfb --- /dev/null +++ b/t/t4063-diff-converted.sh @@ -0,0 +1,32 @@ +#!/bin/sh +# +# Copyright (c) 2

[PATCH 2/2] push: Use "last one wins" convention for --recurse-submodules

2015-12-03 Thread Mike Crowe
Use the "last one wins" convention for --recurse-submodules rather than treating conflicting options as an error. Also, fix the declaration of the file-scope recurse_submodules global variable to put it on a separate line. Signed-off-by: Mike Crowe <m...@mcrowe.com> ---

[PATCH 1/2] push: Fully test --recurse-submodules on command line overrides config

2015-12-03 Thread Mike Crowe
message. Signed-off-by: Mike Crowe <m...@mcrowe.com> --- t/t5531-deep-submodule-push.sh | 32 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/t/t5531-deep-submodule-push.sh b/t/t5531-deep-submodule-push.sh index 9fda7b0..721be32 100755 --- a/t

Re: [PATCH] push: Improve --recurse-submodules support

2015-12-03 Thread Mike Crowe
On Wednesday 02 December 2015 at 15:21:13 -0800, Junio C Hamano wrote: > Mike Crowe <m...@mcrowe.com> writes: > > > b33a15b08131514b593015cb3e719faf9db20208 added support for the > > push.recurseSubmodules config option. After it was merged Junio C Hamano > &g

Re: [PATCH v3] push: add recurseSubmodules config option

2015-12-02 Thread Mike Crowe
On Tuesday 01 December 2015 at 19:40:32 -0500, Jeff King wrote: > On Tue, Dec 01, 2015 at 11:49:43AM +0000, Mike Crowe wrote: > > > The --recurse-submodules command line parameter has existed for some > > time but it has no config file equivalent. > > > > Following

[PATCH] push: Improve --recurse-submodules support

2015-12-02 Thread Mike Crowe
one winning. (This simplified the implementation too.) Also slightly improve one of the tests added in b33a15b08131514b593015cb3e719faf9db20208. Signed-off-by: Mike Crowe <m...@mcrowe.com> --- builtin/push.c | 12 +++- t/t5531-deep-submodule-push.s

[PATCH v3] push: add recurseSubmodules config option

2015-12-01 Thread Mike Crowe
-submodules=no to allow the configuration to be overridden on the command line when required. The most straightforward way to implement this appears to be to make push use code in submodule-config in a similar way to fetch. Signed-off-by: Mike Crowe <m...@mcrowe.com> --- Changes in v3: * Incor

Re: [PATCH] push: add recurseSubmodules config option

2015-11-30 Thread Mike Crowe
On Monday 30 November 2015 at 10:31:26 -0800, Junio C Hamano wrote: > Mike Crowe <m...@mcrowe.com> writes: > > > diff --git a/builtin/push.c b/builtin/push.c > > index 3bda430..dfced74 100644 > > --- a/builtin/push.c > > +++ b/builtin/push.c > >

[PATCHv2] push: add recurseSubmodules config option

2015-11-17 Thread Mike Crowe
of --recurse-submodules=no to allow the configuration to be overridden on the command line when required. The most straightforward way to implement this appears to be to make push use code in submodule-config in a similar way to fetch. Signed-off-by: Mike Crowe <m...@mcrowe.com> --- Documen

[PATCH] push: add recurseSubmodules config option

2015-11-16 Thread Mike Crowe
of --recurse-submodules=no to allow the configuration to be overridden on the command line when required. The most straightforward way to implement this appears to be to make push use code in submodule-config in a similar way to fetch. Signed-off-by: Mike Crowe <m...@mcrowe.com> --- Documen

Re: [PATCH] push: add recurseSubmodules config option

2015-11-16 Thread Mike Crowe
On Monday 16 November 2015 at 10:15:24 -0800, Stefan Beller wrote: > The code itself looks good to me, one nit in the tests though. > > > @@ -79,6 +87,119 @@ test_expect_success 'push succeeds after commit was > > pushed to remote' ' > > ) > > ' > > > > +test_expect_success 'push

[PATCH] describe: Add --left-only option

2013-05-17 Thread Mike Crowe
Only consider the first parent commit when walking the commit history. This is useful if you only wish to match tags on your branch after a merge. Signed-off-by: Mike Crowe m...@mcrowe.com --- Documentation/git-describe.txt | 9 - builtin/describe.c | 5 + t/t6120

Re: [PATCH] describe: Add --left-only option

2013-05-17 Thread Mike Crowe
On Fri, May 17, 2013 at 04:03:29PM +0100, John Keeping wrote: On Fri, May 17, 2013 at 03:24:26PM +0100, Mike Crowe wrote: Only consider the first parent commit when walking the commit history. This is useful if you only wish to match tags on your branch after a merge. For consistency

git diff --quiet on dirty tree sometimes erroneously exits with status 0

2013-04-05 Thread Mike Crowe
I'm seeing a strange problem where git diff --quiet sometimes returns an exit code of zero even though the tree is dirty and other invocations of git diff --quiet in the same directory return an exit code of 1. I'm using git v1.8.2 from Debian unstable but I've also seen the problem when running