Convert text file line delimiters

The simplest way to convert a file's line delimiters from DOS to Unix and back:

# from DOS/Windows to Unix
$ dos2unix filename 

# from Unix to DOS/Windows
$ unix2dos filename