Remove ^M characters from file
Writing by shivdev on Tuesday, 28 of July , 2015 at 10:27 pm
The key is to enter Ctrl+V+M (^M) to simulate this.
on_mac$ sed -i ” -e ‘s/^M//g’ filename
on_linux$ sed -i -e ‘s/^M//g’ filename
This can also be done in vi/vim, but may not work in Sublime Text type editors.
Leave a comment
Category: Linux
- Add this post to
- Del.icio.us -
- Digg -
- -
- Tweet -
-
-
No comments yet.
You must be logged in to post a comment.