Re: [RFC/PATCH] git-gui: Use gitattribute "encoding" for file content display

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Shawn O. Pearce <spearce@...>
Cc: Git Mailing List <git@...>, Johannes Schindelin <Johannes.Schindelin@...>, Jakub Narebski <jnareb@...>, Finn Arne Gangstad <finnag@...>, Junio C Hamano <gitster@...>, Michele Ballabio <barra_cuda@...>
Date: Wednesday, January 23, 2008 - 4:41 am

On Jan 23, 2008, at 6:55 AM, Junio C Hamano wrote:


Shouldn't we first try harder to get things right without adding
an attribute?  Maybe we could continue a good tradition and look
at the content of the first: we could first look for hints in the
file about the encoding.  XML and many text files contain such
hints already to help editors.  For example,  Python source can
explicitly contain the encoding [1]; and I guess there are many
other examples.  If we don't find a direct hint, we could have
some magic auto-detection similar to what we do for autocrlf.  As
a fallback the user could specify a default encoding.  But only
as a last resort, I'd use explicit attributes.

[1] http://www.python.org/dev/peps/pep-0263/

	Steffen
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [RFC/PATCH] git-gui: Use gitattribute "encoding" for fil..., Steffen Prohaska, (Wed Jan 23, 4:41 am)