If you ever open up a file in a Finder application and see lots of little boxes at the end of each line, or if you try to edit a file within Unix and find that it’s littered with ^M sequences, you’ve hit the end-of-line problem.
To fix it, create the following command aliases:
alias m2u="tr '\015' '\012' "
alias u2m="tr '\012' '\015' "
use m2u (Mac to Unix),
$ m2u < mac-format-file > unix-friendly-file
use the reverse (Unix to Mac)
$ u2m < unix-friendly-file > mac-format-file
Designed by sketchbooks.co.kr / sketchbook5 board skin