This one time, at band camp, Daniel Harper wrote:
Anyone know how to rip ^M (dos line return) using sed?
tr -d '\r' will remove ^Ms from a stream.
--
[EMAIL PROTECTED] http://spacepants.org/jaq.gpg
--
SLUG - Sydney Linux User's Group - http://slug.org.au/
More Info:
On 17 Feb 2003 15:05:08 +1100
Ken Foskey [EMAIL PROTECTED] wrote:
On Mon, 2003-02-17 at 13:23, Daniel Harper wrote:
Anyone know how to rip ^M (dos line return) using sed?
without reading the manual you might try 's/\r//g' this is definitely
not portable, if not use hex characters \015 from
On Mon, 2003-02-17 at 20:44, [EMAIL PROTECTED] wrote:
I've never been able to figure out a portable way
to mangle control chars with sed.
if it's cos you're trying to use a dos file then just
run 'dos2unix' over the file (and vice versa use 'unix2dos').
Dave.
--
SLUG - Sydney Linux User's
On 17 Feb 2003 21:07:20 +1030
David Fitch [EMAIL PROTECTED] wrote:
On Mon, 2003-02-17 at 20:44, [EMAIL PROTECTED] wrote:
I've never been able to figure out a portable way
to mangle control chars with sed.
if it's cos you're trying to use a dos file then just
run 'dos2unix' over the file
On Mon, 2003-02-17 at 23:12, [EMAIL PROTECTED] wrote:
Yeah, but I never really trusted those programs, since
(on Solaris at least) they always whinge about character
sets or locales or something.
never had any such problems (linux and solaris)
And it seems my suspicion is not unwarranted:
On 17 Feb 2003 23:09:20 +1030
David Fitch [EMAIL PROTECTED] wrote:
What the hell is that null doing there?
what's wrong with it?
I expected dos2unix to just convert \r\n to a single \n.
I don't expect to get a null in a text file.
Matt
--
SLUG - Sydney Linux User's Group -
Anyone know how to rip ^M (dos line return) using sed?
--
SLUG - Sydney Linux User's Group - http://slug.org.au/
More Info: http://lists.slug.org.au/listinfo/slug
On Mon, 2003-02-17 at 13:23, Daniel Harper wrote:
Anyone know how to rip ^M (dos line return) using sed?
without reading the manual you might try 's/\r//g' this is definitely
not portable, if not use hex characters \015 from memory again...
--
Thanks
KenF
OpenOffice.org developer
--
SLUG -