info-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Using dos2unix on commit???


From: Andy Kriger
Subject: RE: Using dos2unix on commit???
Date: Fri, 13 Jun 2003 15:25:16 -0400

Thanks for the suggestions. I'll try those ideas.

As background, what is prompting this need is multiple developers with
different IDEs making connections to CVS. Since there's no way to be sure
what line format is being used, I'm looking for consistency.

-----Original Message-----
From: Frederic Brehm [mailto:address@hidden
Sent: Friday, June 13, 2003 13:38
To: Andy Kriger; address@hidden
Subject: Re: Using dos2unix on commit???


At 11:47 AM 6/13/2003, Andy Kriger wrote:
>I am trying to setup our Unix-based CVS repository to run dos2unix when
>files are committed, but I'm not having much luck and don't see any
solution
>laid out clearly in the mailing lists.

Don't attempt to use a commitinfo script to change a file being checked in.
It won't work.


>So I thought that dos2unix would get the path combined with filename as an
>argument.

man dos2unix


>Does anyone have an example of this that does work?


Sorry, no. Here's some suggestions, though.

1. Write a script that greps for CRLF in a file. Print an informative error
message telling the user to run dos2unix on the offending files, and then
have the script return false (not zero). Use this script in commitinfo. You
will have to read the documentation about commitinfo again CAREFULLY
because the arguments passed to the script are not what you think. Use
"DEFAULT echo" to experiment, and be sure to cvs add a new directory when
you experiment.

2. If you are checking in from Windows, then use the correct cvs client. If
you are using Cygwin with the default text type of "Unix", then you will
have to use a different cvs client.


Fred

_______________________________________________________________
Frederic W. Brehm, Sarnoff Corporation, http://www.sarnoff.com/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]