All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Torsten Bögershausen" <tboegi@web.de>
To: Michael Haggerty <mhagger@alum.mit.edu>,
	git discussion list <git@vger.kernel.org>
Subject: Re: Surprising interaction of "binary" and "eol" gitattributes
Date: Thu, 05 Mar 2015 21:49:22 +0100	[thread overview]
Message-ID: <54F8C152.7010203@web.de> (raw)
In-Reply-To: <54F88684.3020905@alum.mit.edu>

On 2015-03-05 17.38, Michael Haggerty wrote:
> I would expect that the following .gitattributes file
> 
>     *       eol=crlf
>     *.png   -text
> 
> would leave EOL translation turned off for PNG files. In other words, I
> would expect that explicitly setting "-text" would take precedence over
> the fact that setting "eol" implies that a file should be considered to
> be "text".
> 
> I would even more strongly expect
> 
>     *       eol=crlf
>     *.png   binary
> 
> to turn off EOL translation for PNG files.
> 
> But in fact, in both of the above cases, EOL translation is turned *on*
> for PNG files.
> 
> I propose that "-text" should override any setting for "eol" (which
> would of course fix both problems, since "binary" is equivalent to
> "-diff -merge -text"). What do people think?
> 
> Michael
> 

("binary" is not supported, we need "-text")
Beside that,  

>     *       eol=crlf
>     *.png   -text
should work as you describe.

Do you think you make a test case for this ?
In best case as a real patch :-)

(I know that attributes should take precedence over eol settings in the
config file, and this is not always the case)

  reply	other threads:[~2015-03-05 20:49 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-05 16:38 Surprising interaction of "binary" and "eol" gitattributes Michael Haggerty
2015-03-05 20:49 ` Torsten Bögershausen [this message]
2015-03-05 22:08 ` Junio C Hamano
2015-03-06  5:59   ` Torsten Bögershausen
2015-03-06 17:51     ` Michael Haggerty
2015-03-06 21:30       ` Torsten Bögershausen
2015-03-10 19:25         ` Michael Haggerty
2015-03-10 20:01           ` Junio C Hamano
2015-03-10 22:16             ` Michael Haggerty
2015-03-10 22:54               ` Junio C Hamano
2015-03-11  5:54                 ` Torsten Bögershausen
2015-03-11 17:59                   ` Junio C Hamano
2015-03-11 20:30                 ` Johannes Sixt
2015-03-11 21:31                   ` Junio C Hamano
2015-03-11 21:43                     ` Junio C Hamano
2015-03-10 20:26           ` Torsten Bögershausen
2015-03-10 22:24             ` Michael Haggerty

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=54F8C152.7010203@web.de \
    --to=tboegi@web.de \
    --cc=git@vger.kernel.org \
    --cc=mhagger@alum.mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.