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

Re: Inconsistent line ending style terminates add without message

From: Ryan Schmidt <subversion-2009b_at_ryandesign.com>
Date: Mon, 19 Oct 2009 23:19:27 -0500

On Oct 19, 2009, at 21:07, David Weintraub wrote:

> On Sun, Oct 18, 2009 at 12:13 PM, johnea <me_at_johnea.net> wrote:
>
>> Regarding the files being omitted from the add, does anyone know if
>> this is the expected behavior of svn add, or am I doing something
>> wrong here?
>
> Subversion is suppose to be an all or nothing commit. Either all of
> your changes are committed or none are.
>

> Unless you have a pre-commit trigger or have auto-properties set to
> svn:native, inconsistent line endings shouldn't be a problem. If you
> have a pre-commit trigger that requires particular line endings, the
> commit simply won't go through and none of your changes will be
> committed. You'll get an error message from the pre-commit trigger.

He's not talking about committing. He's talking about adding. He asked
for a bunch of things to be added, and only some of them got added.

> If you have the svn:native property set, and you have inconsistant
> line endings, you'll get an error message stating that the commit
> failed because of inconsistant line endings, and none of your
> changes will be committed.
>

> Otherwise, Subversion simply doesn't care about line endings. There
> is no difference between a binary or nonbinary file the way
> Subversion stores files. We have plenty of files with inconsistant
> line endings, and Subversion has no problems with those.

You mean the "svn:eol-style" property set to the value "native". And
yes, he must have the "svn:eol-style" property set (though it doesn't
matter what value). As you say, Subversion doesn't care about line
endings unless you set "svn:eol-style". The fact that Subversion
printed the error message "Inconsistent line ending style" is clear
indication that line ending translation was requested by the user (but
could not be performed).

> Did all the files get added with the "svn add"?

He already stated they were not:

> On Oct 17, 2009, at 16:07, johnea wrote:
>
>> I am finding that when I do an "svn add" on a source tree with
>> numerous
>> sub-directories, that if there is a "Inconsistent line ending style"
>> error on a file, the directory that file is in is not added.

> Was there an error message on the add?

He stated there was the "Inconsistent line ending style" message, but
the error message did not indicate that the add did not completely
succeed.

> On Oct 17, 2009, at 16:07, johnea wrote:
>
>> There is no indication of this condition presented to the user and
>> the
>> offending directory is silently dropped from the add operation.

> I can't say exactly what happened without more information. All I
> can say is that a commit either works and all files are committed or
> doesn't work and none of the files are committed. That's the way
> Subversion was designed.

He's talking about "svn add", not "svn commit".

This sounds different from but perhaps related to issue 2713, which
was fixed; the fix will be in Subversion 1.7.0.

http://subversion.tigris.org/issues/show_bug.cgi?id=2713

johnea could try building Subversion from trunk to see if the behavior
can still be reproduced.

------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2409238

To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-10-20 06:20:49 CEST

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