From 70f32af39cc49a27e078cfc9b4e2c31c4ba8bd53 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Sun, 16 Oct 2005 12:13:58 +0000 Subject: - Whitespace Cleanups. - Whitespace script improved. Signed-off-by: Mauro Carvalho Chehab --- v4l/scripts/strip-trailing-whitespaces.sh | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'v4l/scripts') diff --git a/v4l/scripts/strip-trailing-whitespaces.sh b/v4l/scripts/strip-trailing-whitespaces.sh index ea4f28752..ea3e4defa 100644 --- a/v4l/scripts/strip-trailing-whitespaces.sh +++ b/v4l/scripts/strip-trailing-whitespaces.sh @@ -10,7 +10,22 @@ for file in `find linux -type d | grep -v CVS | grep -v .cvsignore` ; do done for file in `find linux -type f | grep -v CVS | grep -v .cvsignore` ; do tmpfile="$WORK/${file}.$$" - perl -ne 's/[ \t]+$//; print' < "${file}" > "${tmpfile}" + perl -ne 's/[ \t]+$//; + s/^\ \ \ \ \ \ \ \ /\t/; + s/^\ \ \ \ \ \ \ \t/\t/; + s/^\ \ \ \ \ \ \t/\t/; + s/^\ \ \ \ \ \t/\t/; + s/^\ \ \ \t/\t/; + s/^\ \ \t/\t/; + s/^\ \t/\t/; + s/\t\ \ \ \ \ \ \ \ /\t\t/g; + s/\t\ \ \ \ \ \ \ \t/\t\t/g; + s/\t\ \ \ \ \ \ \t/\t\t/g; + s/\t\ \ \ \ \ \t/\t\t/g; + s/\t\ \ \ \t/\t\t/g; + s/\t\ \ \t/\t\t/g; + s/\t\ \t/\t\t/g; + print' < "${file}" > "${tmpfile}" diff -u "${file}" "${tmpfile}" | sed \ -e "s|^--- ${file}|--- ${file}.orig|" \ -e "s|^+++ ${tmpfile}|+++ ${file}|" -- cgit v1.2.3