subversion-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Geoff Field <Geoff_Fi...@aapl.com.au>
Subject RE: SVN commit line ending handling
Date Sun, 01 Sep 2013 23:09:47 GMT
> From: Ryan Schmidt 
> Sent: Sunday, 1 September 2013 8:21 AM
> On Aug 31, 2013, at 05:29, Edoardo Pinci wrote:
> > I periodically receive this kind of errors since a long time.
> >  
> > X:\>svn commit -m "BLA BLA" itextsharp.dll iTextSharp.xml
> > Sending        iTextSharp.xml
> > Sending        itextsharp.dll
> > Transmitting file data ..
> > svn: E135000: Commit failed (details follow):
> > svn: E135000: While preparing 'iTextSharp.xml' for commit
> > svn: E135000: Inconsistent line ending style

I've seen this a few times when committing an auto-generated XML file - mostly because it
was encoded as UTF-16.

> > svn: E720032: Additional errors:
> > svn: E720032: Transaction '1718-1ca' cleanup failed
> > svn: E720032: Can't remove file 
> 'Depot\db\txn-protorevs\1718-1ca.rev': The process cannot 
> access the file because it is being used by another process.

Since I've been using the TortoiseSVN client, I haven't noticed whether these additional errors
popped up as well.

> > Question 1: Is there a way to have SVN normalize line 
> ending on commit by itself?
> 
> It seems svn:eol-style is set on this file. If you set 
> svn:eol-style on a file (to any supported value), Subversion 
> requires that the file have consistent line endings before 
> you commit it. You or your tools must do this; Subversion will not.

I was going to ask "why not?"  However, I realised this is because the SVN philosophy is to
not change files unless explicitly requested to (with keywords).

> If you do not set svn:eol-style, then Subversion does not 
> check the line endings and lets you commit whatever you want, 
> so if for some reason you want inconsistent line endings then 
> that's how you can have that.

If the file's encoded as UTF-16, it will give this error regardless of the consistency of
the line endings.  I've found the easiest way around this (for me) is to copy and paste the
contents of the XML file into a new file encoded as UTF-8, then save it over the top of the
original file.  Notepad++ is my preferred option for this at the moment, but any text editor
should do the job.

> > Question 2: Why txn-protorevs aren't being cleaned up properly?
> 
> I don't know what's going on there. Do you have any hook 
> scripts? Maybe one of them is programmed incorrectly.


Regards,

Geoff
- The contents of this email, and any attachments, are strictly private
and confidential.
- It may contain legally privileged or sensitive information and is intended
solely for the individual or entity to which it is addressed.
- Only the intended recipient may review, reproduce, retransmit, disclose,
disseminate or otherwise use or take action in reliance upon the information
contained in this email and any attachments, with the permission of
Australian Arrow Pty. Ltd.
- If you have received this communication in error, please reply to the sender
immediately and promptly delete the email and attachments, together with
any copies, from all computers.
- It is your responsibility to scan this communication and any attached files
for computer viruses and other defects and we recommend that it be
subjected to your virus checking procedures prior to use.
- Australian Arrow Pty. Ltd. does not accept liability for any loss or damage
of any nature, howsoever caused, which may result
directly or indirectly from this communication or any attached files. 



Mime
View raw message