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

Re: [PATCH] truncate EDITOR_EOF_PREFIX with previous EOL

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2005-07-22 17:52:43 CEST

Olleg Samoylov wrote:
> kfogel@collab.net wrote:
>
>> Olleg wrote:
>>
>>> I can't undestand official position of subversion developers.
>>> Obviously this is bug because svn don't work as expected. When I
>>> write 1 line message to log, I expect 1 line message in log. Clear
>>> and simple.

Olleg, I agree with you that the behaviour is odd and unpleasant and seems to
be wrong. I also would like the program to remove trailing whitespace, either
when creating or when displaying the log message.

Here is one fact that might make it seem less bad for you: When the Subversion
command-line client prints "2 lines" followed by your one-line log message and
then a blank line, the program is not lying by saying, "Your log message had
two lines," instead it is only saying, "I am going to use two lines to display
your log message." The number is put there only for other computer programs to
use; it is not really meant to be read by you.

>>
>> Well, you didn't write one line :-). You wrote a line, followed by a
>> newline, followed by a line that promised its own removal at commit
>> time, along with everything following it. And that's exactly what
>> happens right now.

(Well, Karl, that's unfair, and you know it!)

> I undestand why this happens. But your can't undestand one simple thing.
> One line message is always one line message. And every human can approve
> it. No matter how computer make wrong decision.

Yes, I agree, except that the computer has definite, valid reasons to use two
lines to display your one-line message. It's not exactly what you or I want,
but it was designed that way on purpose; it did not happen accidentally.

We can argue that making log messages end consistently would be better for us,
but another Subversion user might want to retrieve the log message and feed it
back into the editor that created it; if Subversion had altered the ending,
that might give unpleasant results. So, there is no single behaviour that
everyone can agree is the correct behaviour.

[...]
> There is chose. Rewrite almost code to support log message with trailing
> EOL, as Greg like. Or fix bug. Or do nothing? What your prefer?

("There is a choice.")

Unfortunately for you and me, I think in this situation the best thing is to do
nothing at the moment. In version 2 of the Subversion command-line client, we
could do something different. Other clients, such as TortoiseSVN, can do
something different.

>
> IMHO, will be convenient remove all white spaces at the end, not only
> EOL. They arised by mistype usually. Don't have any useful information.
> And invisible for human to fix it manualy.

Yes, I agree. I would like to use a client that removes all trailing white
space (or replaces it with a single newline control code). I wrote my own
patch last year to do this in a different way, and (IIRC) it also was rejected
by the Subversion team. We will just have to get used to it, or use a patched
or different client program to display the log messages.

- Julian

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Fri Jul 22 17:55:02 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.