From: Misha Brukman Date: Fri, 20 Feb 2009 22:30:46 +0000 (+0000) Subject: Keep the newline character at the end of the lines whose trailing whitespace we X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=d5ece81cc7a908c30e6786b70a4a9db1dd129a8a;p=oota-llvm.git Keep the newline character at the end of the lines whose trailing whitespace we are deleting; otherwise, everything ends up on a single line. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@65185 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/utils/lint/remove_trailing_whitespace.sh b/utils/lint/remove_trailing_whitespace.sh index de58dbab7fc..6e0c9be0932 100755 --- a/utils/lint/remove_trailing_whitespace.sh +++ b/utils/lint/remove_trailing_whitespace.sh @@ -3,4 +3,4 @@ # Sample syntax: # $0 *.cpp -perl -pi -e "s/\s+\$//" $* +perl -pi -e 's/\s+$/\n/' $*