Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-26 Thread Junio C Hamano
Torsten Bögershausen writes: >> +++ b/diff.c >> @@ -2647,6 +2647,10 @@ static int diff_populate_gitlink(struct diff_filespec >> *s, int size_only) >> int diff_populate_filespec(struct diff_filespec *s, int size_only) >> { >> int err = 0; >> +enum safe_crlf crlf_warn = (safe_crlf != SA

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-25 Thread Torsten Bögershausen
> +++ b/diff.c > @@ -2647,6 +2647,10 @@ static int diff_populate_gitlink(struct diff_filespec > *s, int size_only) > int diff_populate_filespec(struct diff_filespec *s, int size_only) > { > int err = 0; > + enum safe_crlf crlf_warn = (safe_crlf != SAFE_CRLF_FAIL > +

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-24 Thread Junio C Hamano
Junio C Hamano writes: > Care to turn it into an appliable patch with tests? In the meantime, here is a quick-and-dirty one. I am not proud of it; it was just something to keep in 'pu' let it gets lost. A better replacement is very much welcomed. -- >8 -- Subject: [PATCH] diff: demote core.sa

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-24 Thread Junio C Hamano
Yann Droneaud writes: > Hi, > > Le 21.06.2013 23:57, Junio C Hamano a écrit : >> Junio C Hamano writes: >> >>> The helper may want to learn a way to be told to demote that error >>> to a warning. >> >> Perhaps something like this? >> > > Thanks for the patch. Care to turn it into an appliable p

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-24 Thread Yann Droneaud
Hi, Le 21.06.2013 23:57, Junio C Hamano a écrit : Junio C Hamano writes: The helper may want to learn a way to be told to demote that error to a warning. Perhaps something like this? Thanks for the patch. I run my test again, eg. run git diff after a rebase failure (see my other mail a

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-21 Thread Junio C Hamano
Junio C Hamano writes: > The helper may want to learn a way to be told to demote that error > to a warning. Perhaps something like this? diff.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/diff.c b/diff.c index f0b3e7c..9b4f3ac 100644 --- a/diff.c +++ b/diff.c @@ -2

Re: git diff returns fatal error with core.safecrlf is set to true.

2013-06-21 Thread Junio C Hamano
Yann Droneaud writes: > While testing the behavor of Git regarding CRLF handling, > when core.safecrlf is set to true, I've found that "git diff" is > returning > "fatal: CRLF would be replaced by LF" without returning any kind of > diff. > > This make me wonder if its the correct behavor for git

git diff returns fatal error with core.safecrlf is set to true.

2013-06-21 Thread Yann Droneaud
Hi, Following my previous email "Tracking vendor release with Git" [1][2], and the advice from Git users/developers, I'm trying to use .gitattributes to handle CRLF/LF conversion. While testing the behavor of Git regarding CRLF handling, when core.safecrlf is set to true, I've found that "git