Warning: Illegal string offset 'lang' in /home/content/80/4113280/html/techtouch.ca/blog/wp-content/plugins/keyword-statistics/keyword-statistics.php on line 350

Warning: Illegal string offset 'keywords' in /home/content/80/4113280/html/techtouch.ca/blog/wp-content/plugins/keyword-statistics/keyword-statistics.php on line 354

Warning: Illegal string offset 'description' in /home/content/80/4113280/html/techtouch.ca/blog/wp-content/plugins/keyword-statistics/keyword-statistics.php on line 356

Admin Life Errors, Fixes, and Encounters

10Feb/101

vi search and replace ^M

To easily search and replace the ^M (new line) character in vi use the following command. Make sure your in command mode and not input mode when you do it.

:%s/^M$//g

to get the proper ^M in vi you'll need to do CTRL-v CTRL-M and that should display ^M

Filed under: commands, Errors, Unix 1 Comment