Clean up CTRL-M ( ^M ) chars

using VI while the file is open :  :%s/^M$//g
using sed :   cat file | |sed 's/^M$//' > newfile
using dos2unix :  http://www.linuxcommand.org/man_pages/dos2unix1.html
using tr :   tr -d "\015" < filename > newfile

Leave a Comment


NOTE - You can use these HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>