perl -pi.bak -e 's/^M//g' *.xml #### perl -pi.bak -e 's/^M//g' testfile.html