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

Re: "Inconsistent newlines": A clue

From: Michael W Thelen <mike_at_pietdepsi.com>
Date: 2005-02-09 19:41:41 CET

David Kramer wrote:
>>>It would be more user-friendly to report *all* the problem files after
>>>a single run. This might be complex to implement, but it's certainly
>>>possible, and I wouldn't be averse to an enhancement issue being filed
>>>about it. What do you think?
>>>
>>
>>I'm not sure I understand the proposal. One runs 'svn import', and
>>then 20 minutes in, you see a message like
>>
>> svn: file X has inconsistent newlines
>> svn: this commit will fail, but continuing to search for other such
>>files...
>>
>>?
>>
>>Perhaps a better solution is a tool to go into contrib/ which will scan
>>a directory for files with this problem. It can be used as a
>>"pre-flight" check before large imports.
>>
>
>
> Yes, that's an excellent suggestion.
>
> And perhaps I should be the one to write it. I just found out Monday my
> contract is being terminated, so I should have hte time ;)

It may or may not be exactly what you want, but I wrote a script a few
months ago that automatically sets properties as listed in the
auto-props section of your config file. It's useful if you have checked
in a bunch of files without using auto-props, and want to set properties
as if you had used auto-props. It also detects inconsistent newlines
and can try to fix them (that may only work on Linux, I haven't had time
to test it on Windows). In your case, maybe you could simply turn off
auto-props, import your files, then run this script.

The latest version of the script lives here:
http://svn.pietdepsi.com/repos/projects/svn-tools/set-props.pl

I also posted a version to the dev@ mailing list here:
http://svn.haxx.se/dev/archive-2004-07/0866.shtml

and Ben Reser said he would commit it here:
http://svn.haxx.se/dev/archive-2004-09/0038.shtml

but it was probably simply forgotten. I hope you find it useful!

--
Michael W Thelen
It is a mistake to think you can solve any major problems just with
potatoes.       -- Douglas Adams

Received on Wed Feb 9 19:44:11 2005

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.