Re: replacing ^M in the editor



Quoting Pavel Roskin <proski gnu org>:

Strictly speaking, you asked to replace ^M (presumably with some other
text), not to remove it.  Also, you didn't say that you are dealing with
DOS text, where ^M always precedes the newline.

It's easy to emulate functionality of dos2unix in mcedit.  Select F4
(Replace).  Then enter:

Enter search string:
. Ctrl-q Enter

Enter replacement string:
Ctrl-q Enter

Select "Regular expression".  Press OK.  That's it.

This is some excercise to do rather common operation 
(common at least to me... ;-)...)

Maybe I dare to suggest new MC command (presumably in FILE pull-down menu):
"Convert", with options: 
MS-DOS -> Unix
Unix   -> MS-DOS

and maybe for Apple etc.

And possibly with the option to save with different name (with "Save as...."
prefilled with current name).

I know I'll like to have it many times... ;-)

-- 
Peter Masiar, peter masiar yale edu, (203) 764-8131
I am not a lawyer. My ideas are NOT binding for University.
In doubt, Yale policy right: http://www.yale.edu/policy/itaup.html 





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]