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

RE: Re: MIME Type for SVG images in SVN config

From: Gleason, Todd <tgleason_at_impac.com>
Date: Fri, 20 Jun 2008 15:51:26 -0700

I'd like to add another observation to that. If you want to plug in a custom merge tool, I believe you have to mark your svn:mime-type as a text type as well. It seems strange that, when you want to plug in something special to do a binary diff, that you are indicating it's text, when it may be an image, a document, or a database of some form. And it gets additionally confusing in that you start asking whether you need to worry about eol-style when you want to make sure that no conversion happens whatsoever on what is really a binary file.
I would much rather have a property to indicate that the file was mergeable, rather than, again, coercing the MIME-type to be able to plug in a merge tool.

And yes, I have read http://svnbook.red-bean.com/en/1.4/svn.advanced.externaldifftools.html and although I'm very thankful for the documentation, it still seems strange to me.

-----Original Message-----
From: kogrover_at_gmail.com [mailto:kogrover_at_gmail.com] On Behalf Of Kevin Grover
Sent: Friday, June 20, 2008 3:59 PM
To: Jan Hendrik
Cc: users_at_subversion.tigris.org
Subject: Re: MIME Type for SVG images in SVN config

On Fri, Jun 20, 2008 at 12:13 AM, Jan Hendrik
<list.jan.hendrik_at_gmail.com> wrote:
> Concerning Re: MIME Type for SVG images in SVN
> Kevin Grover wrote on 19 Jun 2008, 22:18, at least in part:
>> On Thu, Jun 19, 2008 at 12:05 PM, Jan Hendrik
>> <list.jan.hendrik_at_gmail.com> wrote:
>> > Have there been any considerations about excepting */*+xml types in
>> > general as suggested in that thread back in 2004? Supposing of
>> > course that XML never can be binary. Or is there an intention to
>> > limit folks screwing up XML in plain text editors when they rather
>> > should use the proper application?
>> >
>> I don't remember that particular conversation, but I remember others.
>> Personally, instead of adding more exceptions to the svn:mime-type,
>> I'd rather see a more generic approach:
>> 1) All files are binary by default (current situation)
>> 2) You mark a file as text with a property: this is the current
>> situation. I would propose a change. I'd vote for svn:text-file
>> (some similar) as a new property. It could be set to '*' (like
>> svn:executable) or even to an eol setting (replacing svn:eol-style)
>> and/or encoding. We could have related properties
>> svn:text-file-eol-style and/or svn:text-file-encoding. If any are set
>> the file is text, otherwise it's binary. svn:mime-type can be
>> whatever you need it to be without affecting whether the file is text
>> or not). This is sort-of the way it is. However, the property used
>> it svn:mime-type and it's not obvious which files are text. Or at
>> least, it's not obvious what the expectations to anything other than
>> 'text/*' is binary. This would have to be made in
>> or, as a consolidated property, svn:text (if set to anything) means
>> the file is text, it could further have the optional settings eol:
>> [native, cr, crlf, lf, any, ?]; encoding: [utf8, latin-1, ...]
>> The second syntax could be extended to add new attribute values
>> without affecting future version compatibility.
> Indeed. Exceptions are not very good, in the end nobody but a few
> insiders knows what all is excepted and results could be very
> unexpected.
> Of course I can hear the outcry: Don't do that, MIME is the official
> regular legal way, anything else will confuse people, make them
> screw up binary files, is irregular, illegal, and a big crime having the
> smell of big company imposing propriatary non-standards on the
> community of users.
> Jan Hendrik
> ---------------------------------------
> Freedom quote:
> Die Freiheit ist die Seele von allem, ohne sie ist alles tot.
> Ich will, daß man sich dem Gesetz unterwirft, aber nicht als Sklave.
> -- Katharina die Große (1729-1796)
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
> For additional commands, e-mail: users-help_at_subversion.tigris.org

Sorry to keep beating this dead horse, but I felt the need to point
that while MIME is the _standard_ for file intended usage. It is
_not_ the definitive standard for (nor does it even care) if a file is
text or binary.

A perfect example is SVG. To most of the world, SVG files are images
first. The fact that the files are text (and XML) make absolutely no
difference: they are _used_ as images.

The text/binary issue is what SVN is concerned with. Rather than try
to re-purpose MIME types with a non-indended usage, it would be
clearer to have an explicit SVN marker (property) stating whether a
file is text (svn:text or similar). An explicit (per-repository)
configuration would be as acceptable (and possibly easier to maintain

It would also be possible to add some config logic to SVN so that
admins could list the MIME Types to treat as text. However, I find
this solution 'less correct' than an explicit type because the
functionality is hidden. Also, currently, this type of config is per
user (or a best, per client machine), not repository, which makes
consistency difficult to maintain (within repositories) and increases
confusion - particularly with new users.

- Kevin

To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org

To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-06-21 00:52:03 CEST

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.