Re: Detecting CR eol

2010-09-09 Thread Nico Kadel-Garcia
On Wed, Sep 8, 2010 at 11:27 AM, Campbell Allan wrote: > The part of the book that I felt was relevant is when the line ending is set > to native subversion will store the file in the repository with LF's only. > The client is then changing this to reflect the preferences of the client OS. Yeah,

Re: Detecting CR eol

2010-09-09 Thread Campbell Allan
On Wednesday 08 Sep 2010, Csaba Raduly wrote: > Hi Giulio, > > On Wed, Sep 8, 2010 at 10:25 AM, Giulio Troccoli wrote: > > I am writing a pre-commit hook script in perl. One of the requirement is > > that all files (luckily they are all text files) have the svn:eol-style > > property set to LF an

Re: Detecting CR eol

2010-09-09 Thread Campbell Allan
On Wednesday 08 Sep 2010, Ryan Schmidt wrote: > On Sep 8, 2010, at 10:27, Campbell Allan wrote: > > Before sending my previous reply I had tested it with a file changed > > using unix2dos. Prior to the commit svn diff only shows the text changes > > ignoring the line endings. I haven't explicitly

Re: Detecting CR eol

2010-09-08 Thread Ryan Schmidt
On Sep 8, 2010, at 10:27, Campbell Allan wrote: > Before sending my previous reply I had tested it with a file changed using > unix2dos. Prior to the commit svn diff only shows the text changes ignoring > the line endings. I haven't explicitly tested changing a single line ending > within the

Re: Detecting CR eol

2010-09-08 Thread Ryan Schmidt
On Sep 8, 2010, at 07:45, Campbell Allan wrote: > On Wednesday 08 Sep 2010, Csaba Raduly wrote: > I don't believe you have to go to so much trouble in the pre-commit hook. If > you have set the svn:eol-style property then subversion will ensure the file > has those line endings on checkout and up

Re: Detecting CR eol

2010-09-08 Thread Campbell Allan
On Wednesday 08 Sep 2010, Giulio Troccoli wrote: > > I don't believe you have to go to so much trouble in the > > pre-commit hook. If you have set the svn:eol-style property > > then subversion will ensure the file has those line endings > > on checkout and update them when committing into the > >

RE: Detecting CR eol

2010-09-08 Thread Giulio Troccoli
> On Wednesday 08 September 2010, Giulio Troccoli wrote: > > I remeber having problems with svn:eol-style set to native. I think > > Subversion did not checkout the files with the correct EOL based on > > the platform, but maybe that was because the files were > actually being > > committed with mi

Re: Detecting CR eol

2010-09-08 Thread Ulrich Eckhardt
On Wednesday 08 September 2010, Giulio Troccoli wrote: > I remeber having problems with svn:eol-style set to native. I think > Subversion did not checkout the files with the correct EOL based on > the platform, but maybe that was because the files were actually > being committed with mixed EOLs.

RE: Detecting CR eol

2010-09-08 Thread Giulio Troccoli
> I don't believe you have to go to so much trouble in the > pre-commit hook. If you have set the svn:eol-style property > then subversion will ensure the file has those line endings > on checkout and update them when committing into the > repository. So all the hook needs to do is check for the >

Re: Detecting CR eol

2010-09-08 Thread Campbell Allan
On Wednesday 08 Sep 2010, Csaba Raduly wrote: > Hi Giulio, > > On Wed, Sep 8, 2010 at 10:25 AM, Giulio Troccoli wrote: > > I am writing a pre-commit hook script in perl. One of the requirement is > > that all files (luckily they are all text files) have the svn:eol-style > > property set to LF an

Re: Detecting CR eol

2010-09-08 Thread Csaba Raduly
Hi Giulio, On Wed, Sep 8, 2010 at 10:25 AM, Giulio Troccoli wrote: > I am writing a pre-commit hook script in perl. One of the requirement is that > all files (luckily they are all text files) have the svn:eol-style property > set to LF and the actual eol is indeed LF. If that's not the case I

Detecting CR eol

2010-09-08 Thread Giulio Troccoli
I am writing a pre-commit hook script in perl. One of the requirement is that all files (luckly they are all text files) have the svn:eol-style property set to LF and the actual eol is indeed LF. If that's not the case I will reject the commit and direct the user to a page on our intranet to exp