Re: replacing ^M in the editor


In mc 4.6.0 I would like to replace CR characters that show up as white
on black ^M in the editor. How do I do that?

It looks like it's broken now :-(

Ctrl-q allows you to enter the next symbol as is, without interpretation.
However, Ctrl-M is translated to Enter (Ctrl-J).  I'm not sure if it can
be fixed, but I'll have a look.

Maybe mc should recognize C-style literals, like \r and \0x0D, but it's
not implemented yet.

I'm sorry, but it looks like you'll have to use sed for now:

sed $'s/\r/TEXT_TO_REPLACE/'

Pavel Roskin

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