Using tr to emulate dos2unix Posted on May 14, 2009 by apomeroy As pointed out in many postings and sites, one can use tr to remove octal 015 (^M or CR) tr -d '\015' < oldfile > newfile