diff --git a/htdocs/sql/scripts/remove_control_m.sh b/htdocs/sql/scripts/remove_control_m.sh new file mode 100755 --- /dev/null +++ b/htdocs/sql/scripts/remove_control_m.sh @@ -0,0 +1,23 @@ +#!/bin/sh +# +# $Id: remove_control_m.sh 5152 2003-11-18 15:20:45Z nijel $ +# +# Script to remove ^M from files for DOS <-> UNIX conversions +# + +if [ $# != 1 ] +then + echo "Usage: remove_control_m.sh " + echo "" + echo "Example: remove_control_m.sh php3" + exit +fi + +for i in `find . -name "*.$1"` + do + echo $i + tr -d '\015' < $i > ${i}.new + rm $i + mv ${i}.new $i + done; +