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

Re: svn and automatic line ending

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2005-01-16 16:23:00 CET

Karl Berry wrote:
> [auto-props]
> * = svn:eol-style=native
>
> the proposal is to make
>
> $ svn add text1 image1.gif text2 image2.gif
> A text1
> svn: File 'image1.gif' has binary mime type property
> $
>
> continue to add text2 and image2.gif, instead of giving up after the error.

Do you mean: give a warning and not add image1.gif; then continue to add text2
and try (but fail) to add image2.gif? That might be reasonable.

I think you meant: add image1.gif and set its EOL style to "native" and give a
warning; then continue. That would be bad. I strongly advise against setting
svn:eol-style on non-text files. Even if the current client ignores it when
the MIME type indicates non-text, we have had a discussion about making the
client obey svn:eol-style regardless of MIME type, because that would be useful
in the case of MIME types that Subversion doesn't recognise but that are
nevertheless for text files.

Subversion marks files that it thinks are binary with
"svn:mime-type=application/octet-stream". What you want is for all other files
to have "svn:eol-style=native". It would be convenient if Subversion provided
a way to do what you want directly, but I think a reasonable solution for your
purpose is to run (after the "svn add") a simple program that sets
svn:eol-style on all files that do not have svn:mime-type. Would that be
acceptable?

- Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Jan 16 16:24:16 2005

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

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