help editing files in linux!!

Rick Stevens rstevens at vitalstream.com
Wed Mar 29 02:27:00 UTC 2006


On Tue, 2006-03-28 at 21:18 -0500, jludwig wrote:
> On Tuesday 28 March 2006 8:59 pm, mike wrote:
> > i'm ftping a linux config file over to windows and editing it in windows.
> > when i send it back to linux i see all these ^M characterse in the doc. 
> > how do i edit it in a safe way or how do i prevent the garbling on the
> > return back to linux?
> The end of line return controls charactors different for Linux and M.S. 
> windoz.
> There is a command line program dos2unix that will convert the EOL charactors 
> though.

Caveat:  Be careful using dos2unix or unix2dos.  They will change the
permissions on the file to 644 REGARDLESS of what your umask is or what
the original permissions of the file were.

This is NOT mentioned anywhere in the documentation.  I've been bit by
it before.

----------------------------------------------------------------------
- Rick Stevens, Senior Systems Engineer     rstevens at vitalstream.com -
- VitalStream, Inc.                       http://www.vitalstream.com -
-                                                                    -
-      "Doctor!  My brain hurts!"  "It will have to come out!"       -
----------------------------------------------------------------------




More information about the Redhat-install-list mailing list