Beefy Boxes and Bandwidth Generously Provided by pair Networks vroom
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Remove the ^M Character from a Document

by thaigrrl (Monk)
on Jan 04, 2001 at 18:15 UTC ( [id://49827]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Remove the ^M Character from a Document

Or... in solaris you can do:
dos2unix <filename> <newfilename>
  • Comment on Re: Remove the ^M Character from a Document

Replies are listed 'Best First'.
Re: Re: Remove the ^M Character from a Document
by KM (Priest) on Jan 04, 2001 at 18:28 UTC
    You can get a dos2unix (and unix2dos) for any flavor of UNIX/BSD.

    Cheers,
    KM

Re: Re: Remove the ^M Character from a Document
by mirod (Canon) on Jan 04, 2001 at 20:01 UTC

    The problem is that dos2unix removes ^M, while I often have to replace them by spaces (in the SGML exported by FrameMaker for example), so I end up doing:

    perl -pi e's{\r}{ }g;'

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://49827]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.