
# crlf2lf.sh

# Conversion of one single file with <cr><lf> end of line character to <lf> only.
# To convert a whole directory tree, use the following command:
# find . -name "*.[ch]" -exec crlf2lf.sh {} \;


echo "translating file $1"
tr -d "\015" < $1 > helpfile.txt

# keep old file date/time
touch -r $1 helpfile.txt

# get rid of temporary file
mv helpfile.txt $1

