[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: line ending conversions
From: |
Matt McClure |
Subject: |
Re: line ending conversions |
Date: |
09 Oct 2001 13:10:57 -0400 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 |
On Tue Oct 09 2001, 11:08, Roman Belenov <address@hidden> wrote:
> Matt McClure <address@hidden> writes:
>
> > But I have also noticed some text files in my repository that have CRLF
> > line endings. I think I understand how this happened, but just to
> > confirm...
> >
> > The files were created with GNU Emacs on Windows 2000, which uses CRLF
> > line endings, by default. They were committed to the repository using
> > Cygwin CVS. Does Cygwin CVS assume that LF is the "form appropriate to
> > the operating system on the client", and thus neglect to convert the
> > line endings?
>
> Cygwin has concept of binary and text mounts (you can use 'mount'
> command without arguments to check mount point types on your
> system). In binary-mounted directories, CRLF<->LF translation is
> not done for text files so that LF itself is treated as line ending.
Thanks. I remounted the directory in textmode. But it still seems that
files I add to the repository get added with the CRLF line endings.
[mlm CVSROOT]$ pwd
/cygdrive/c/home/mlm/tmp/CVSROOT
[mlm CVSROOT]$ mount
C:\cygwin\bin on /usr/bin type system (binmode)
C:\cygwin\lib on /usr/lib type system (binmode)
C:\cygwin on / type system (binmode)
c: on /cygdrive/c type system (textmode)
[mlm CVSROOT]$ cat > test
a line with a CRLF ending
[mlm CVSROOT]$ cat -A test
a line with a CRLF ending^M$
[mlm CVSROOT]$ cvs add -m "" test
cvs server: scheduling file `test' for addition
cvs server: use 'cvs commit' to add this file permanently
[mlm CVSROOT]$ cvs ci -m "" test
RCS file: /usr/local/mvroot/CVSROOT/test,v
done
Checking in test;
/usr/local/mvroot/CVSROOT/test,v <-- test
initial revision: 1.1
done
cvs server: Rebuilding administrative file database
In the repository:
address@hidden CVSROOT]$ cat -A test,v
head^I1.1;$
access;$
symbols;$
locks; strict;$
address@hidden @;$
$
$
1.1$
date^I2001.10.09.16.44.16;^Iauthor mlm;^Istate Exp;$
branches;$
next^I;$
$
$
desc$
@@$
$
$
1.1$
log$
@*** empty log message ***$
@$
text$
@a line with a CRLF ending^M$
@$
Similarly, if I check out a file that has LF line endings in the
repository, they are not translated into CRLF line endings on my
machine.
Any ideas?
--
Matt
http://www.faradic.net/~mmcclure/
"I don't believe in rivalries. I don't believe in curses. Wake
up the damn Bambino, maybe I'll drill him in the (behind)."
-Pedro Martinez