Hi Bret
There is nothing strange about this at all. From your other posts (not
necesarily this thread) I'll bet the input file was created/written to
from one of your PCs via Samba, correct?
Well, DOS uses \r\n as it's line termintor, unix uses \n, and mac uses
\r.
Unix utilities don't do anything automatically to modify these for you, so
you have to do it yourself.
Do a 'od -c file | less' on any text file to see what I mean. Try it on
something you did from windows, And then something from unix (like
/etc/hosts)
^M is just whatever tools you are using (like emacs) displays these
sequence of characters. vi by default doesn't show them.
hth
charles
On Mon, 31 Jul 2000, Bret Hughes wrote:
> Thanks to all who responded. For the record, the solution I came up with
> was tr. The echo -n I could not get to work in this situation. I believe
> it was because the ^M was already there. It appears from the man page
> that echo -n will merely keep a ^M from being appended. This is a weird
> thing that I have yet to really get my head around. It took a tr -d
> "\n,\r" to get the functionality I needed. \n or \r alone would not do
> it. What the heck does ^M do anyway? I thought that dos did the cr lf
> deal seperatly and *nixes used just on but from my experiments it would
> appear that the were both ther even though only a singel ^M showed up.
>
> Thanks again to all.
>
> Bret
--
To unsubscribe: mail [EMAIL PROTECTED] with "unsubscribe"
as the Subject.