public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* can Cygwin CVS change line endings on checkout/update?
@ 2002-09-21 20:21 David M. Karr
  2002-09-22  1:14 ` Nicholas Wourms
  2002-09-22  2:50 ` Igor Pechtchanski
  0 siblings, 2 replies; 8+ messages in thread
From: David M. Karr @ 2002-09-21 20:21 UTC (permalink / raw)
  To: cygwin

I've noticed that WinCVS has a feature where it can change the line endings on
files on checkout/update, to either use DOS or Unix line endings.  I don't see
anything in the Cygwin CVS interface that can do this.  Is this feature just
not in standard command-line CVS?

-- 
===================================================================
David M. Karr          ; Java/J2EE/XML/Unix/C++
dmkarr@earthlink.net


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 8+ messages in thread
* RE: can Cygwin CVS change line endings on checkout/update?
@ 2002-09-22 21:18 ASH, JAMES (SBCSI)
  0 siblings, 0 replies; 8+ messages in thread
From: ASH, JAMES (SBCSI) @ 2002-09-22 21:18 UTC (permalink / raw)
  To: dmkarr, cygwin

First of all, you should always make efforts to be sure that your CVS files
are stored using the *UNIX* line ending conventions, whether you are using a
client on DOS/Windows or not, whether your CVS server is running on
DOS/Windows or Unix. If you do not, you *will* have trouble with diffs, and
CVS may tell you a file is out of date when it is not.

Second, the Cygwin CVS (as I believe the "stock" CVS) is aware of line
endings and what to do with them. In a nutshell, a Windows client will
convert the endings before commiting to CVS.

If you are using a DOS text mount on your client machine, and your files
contain DOS CR/LF endings, the client will convert the line endings to UNIX
for you when you commit, and convert back to CR/LF when you checkout/update.
It is smart this way.

If you are using a binary mount on your client machine, the CVS client will
*NOT* do any conversion. It will assume that you are already using Unix line
endings (because you have a binary mount) and will leave them as is. This
will lead to CR/LF in your repository (which you do not want).

In our shop, the recommendation is to use DOS text mounts on your client
machine so that the line endings are handled properly by CVS on checkout and
commit. 

We make this recommendation because, if you use binary mounts, and happen to
save something using a Windows editor, or any Windows IDE, that editor will
save your local files with DOS endings. When you commit, CVS will not
convert endings because of the binary mounts. You end up with CR/LF in your
repository, and this can cause false diffs.

Sorry to ramble. Hope this helps. 

-----Original Message-----
From: dmkarr@earthlink.net [mailto:dmkarr@earthlink.net]
Sent: Saturday, September 21, 2002 10:21 PM
To: cygwin@cygwin.com
Subject: can Cygwin CVS change line endings on checkout/update?


I've noticed that WinCVS has a feature where it can change the line endings
on
files on checkout/update, to either use DOS or Unix line endings.  I don't
see
anything in the Cygwin CVS interface that can do this.  Is this feature just
not in standard command-line CVS?

-- 
===================================================================
David M. Karr          ; Java/J2EE/XML/Unix/C++
dmkarr@earthlink.net


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2002-09-23  3:01 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-21 20:21 can Cygwin CVS change line endings on checkout/update? David M. Karr
2002-09-22  1:14 ` Nicholas Wourms
2002-09-22  2:50 ` Igor Pechtchanski
2002-09-22  9:40   ` Bruce Alderson
2002-09-22  9:55     ` can cygwin " Christopher Faylor
2002-09-22 14:01       ` Nicholas Wourms
2002-09-22 17:06         ` Christopher Faylor
2002-09-22 21:18 can Cygwin " ASH, JAMES (SBCSI)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).