Re: [PATCH 3/3] grep: stop looking at random places for .gitattributes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/11/2012 07:55 AM, Johannes Sixt wrote:
> Am 10/10/2012 21:44, schrieb Junio C Hamano:
>> Johannes Sixt <j.sixt@xxxxxxxxxxxxx> writes:
>>
>>> Is there already an established definition which the "correct"
>>> .gitattributes are?
>>
>> No, and it is deliberately kept vague while waiting for us to come
>> up with a clear definition of what is "correct".
> ...
>> Very often, people
>> retroactively define attributes to correct earlier mistakes.
> 
> Absolutely. I have Windows resource files that are Shift-JIS encoded
> checked in long ago, and I want to retoactively declare them with
> "encoding=Shift-JIS" because I prefer to see Japanese script in gitk
> rather than gibberish.

Maybe I'm being too much of a purist, but I don't think that git should
retroactively reinterpret history on its own initiative in a way that
might not be correct (e.g., maybe your encoding changed from ASCII to
Shift-JIS sometime in the past).  It would be more appropriate for this
to happen only if explicitly requested by the user.  For example, why
don't you override the incorrect historical attributes via
.git/info/attributes?

Michael

-- 
Michael Haggerty
mhagger@xxxxxxxxxxxx
http://softwareswirl.blogspot.com/
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]