[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: 'svn add' succeeds but errors out because file 'has binary mime type property'

From: Sean McBride <sean_at_rogue-research.com>
Date: 2006-07-14 23:22:48 CEST

On 2006-07-13 14:25, Ted Dennison said:

>> 3) utf16 files should be autodetected as text, not binary
>>
>I'm not a Subversion dev, but I'm curious how would one go about doing
>this? Normal text files can be detected by the fact that no byte in them
>is larger than 7F.

That's only true if you're talking about plain ASCII. Other encodings
like MacRoman, UTF-8, ISO 8859, use the upper 128 chars for things like
accented characters, see:
<http://en.wikipedia.org/wiki/Extended_ASCII>

I don't know, but I figured svn would be looking for patterns of CR/LF
chars to guess if something is text. There is no sure-fire way to know
of course.

UTF-16 could also be detected by the BOM:
<http://en.wikipedia.org/wiki/Byte_Order_Mark>

-- 
____________________________________________________________
Sean McBride, B. Eng                 sean@rogue-research.com
Rogue Research                        www.rogue-research.com 
Mac Software Developer              Montréal, Québec, Canada
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Fri Jul 14 23:23:55 2006

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.