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

Re: line-ending conversion and keyword substitution

From: Greg Hudson <ghudson_at_MIT.EDU>
Date: 2001-12-13 01:13:31 CET

On Wed, 2001-12-12 at 17:43, Bruce Atherton wrote:
> In that case, I guess I should submit a proposal of what I understood your
> proposal to be, since I think it has the benefits of Greg's system without
> requiring the flip-flopping of line endings in the repository.

I wouldn't be too disappointed at your proposal being implemented, but I
think I'm still fond of mine because:

  1. It's simpler.
  2. Its integrity guarantees (such as they are) are rock-solid.

To illustrate 2, I'll go back to my little vector graphic example.
Let's say I'm on Windows, and we're using your newline proposal. I
create my no-vectors graphic file, save it, and check it in. Let's say
the initial contents are "VEC\n", which would be a little odd,
especially for a Windows program, but this is a binary format; it could
be anything. Then, next week, I check out the file. Even though it
came from Windows, my client transforms the file contents to "VEC\r\n",
because it has no idea where the file came from; it just thinks it looks
like a Unix text file. I load the file in my vector graphics program
and, because this is my example, the program is forgiving enough not to
lose due to that particular LF -> CRLF translation, and still sees the
file as empty.

Now I create my complex engine design, save the file, and commit it.
Because the client transformed LF to CRLF, on commit it decides it needs
to transform CRLF to LF, destroying the engine design.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 21 14:36:52 2006

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.