- #!/bin/sh
- if [ "$1" = "-h" ] || [ "$1" = "" ]; then
- printf "\n\tUsage : `basename $0` {files}\n"
- printf "\n\t- Convert text file from DOS format to ISO format\n\n"
- else
- for i in $*; do
- if [ -f $i ]; then
- tr -d "\r" < $i > /tmp/cr2lf.$$
- cat /tmp/cr2lf.$$ > $i # retains permissions.
- rm /tmp/cr2lf.$$
- else
- echo $0": " $i "does not exist." >&2
- fi
- done
- fi
|