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

Re: Detecting CR eol

From: Ryan Schmidt <subversion-2010b_at_ryandesign.com>
Date: Wed, 8 Sep 2010 11:59:57 -0500

On Sep 8, 2010, at 10:27, Campbell Allan wrote:

> Before sending my previous reply I had tested it with a file changed using
> unix2dos. Prior to the commit svn diff only shows the text changes ignoring
> the line endings. I haven't explicitly tested changing a single line ending
> within the file but have done a quick concatenation test with half the file
> with LF and the other half CRLF. When committed the entire file in the
> working copy is changed to LF.

As I recall, if a file with svn:eol-style set has inconsistent line endings (e.g. some LF, some CRLF), Subversion will reject the commit and require the user to make the file's line endings consistent before proceeding. Though I don't know whether this is happening on the client or on the server.

> The part of the book that I felt was relevant is when the line ending is set
> to native subversion will store the file in the repository with LF's only.
> The client is then changing this to reflect the preferences of the client OS.

My understanding is that if svn:eol-style is set to *any value* then the repository stores the file with LF line endings and the client does eol translation to your desired style.
Received on 2010-09-08 19:01:11 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.