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

Re: svn diff shows entire file as modified after add 1 character

From: Andy Levy <andy.levy_at_gmail.com>
Date: Mon, 6 Apr 2009 20:13:31 -0400

On Mon, Apr 6, 2009 at 19:20, Andrey Repin <anrdaemon_at_freemail.ru> wrote:
> Greetings, Thornock, Brian (Brian)!
>> The "svn diff" command seems to be inconsistent across various files in my Java repository.
>> I imported several java files from ClearCase into a Subversion repository. The "eol-style" property is set to "native".
> Don't use "native" ever :) it's a way to confusion, and you just ran into it.

Native works perfectly fine, provided you don't have an editor which
tries to "help" by messing with EOL characters itself and instead just
makes things worse.

>> For me to reproduce, I test with 2 files in the same package and directory:
>> *I checkout the repository: svn co http://svn/repos/trunk  ./code-devel
>> *svn diff TestClient.java = reports no change
>> *Open TestClient.java in VI, add a single line in the header comment section
>> *svn diff TestClient.java = shows the diff with the 1 extra line
>> *svn diff TestConnector.java = reports no change
>> *Open TestConnector.java in VI, add a single line in the header comment section
>> *svn diff TestConnector.java = reports every line changed
>> There are about 20 files scattered throughout our base in various packages that have this weird problem where once you change something in the file, every line says it's modified. Even if I delete
>> the line, it still reports every line as modified; I have to svn revert these 20 files. All the other files behave as expected.
> Your diff showing changes in EOL style as (actual) changes in file.
> (Addition/Removal of <CR> character most likely.)
> It is indication that your editor do not agree with your SVN client on
> nativity of given EOL marks.
> Try
> svn diff -x -b .../file
> This should give results equal to the --ignore-eol-style, just in more clear
> way. (Assuming you know the meaning of -b switch) ;)
> For myself, I always use LF only, except when I sure know it would harm the
> results. (I.e. windows batch files)
> --
> WBR,
>  Andrey Repin (anrdaemon_at_freemail.ru) 07.04.2009, <3:07>
> Sorry for my terrible english...
> ------------------------------------------------------
> http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=1567353
> To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].


To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-04-07 02:14:19 CEST

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