[OE-core] [Patch v2 1/1] create-pull-request: detect trailing white space

nitin.a.kamble at intel.com nitin.a.kamble at intel.com
Tue Dec 11 17:28:03 UTC 2012


From: Nitin A Kamble <nitin.a.kamble at intel.com>

Add logic in the create-pull-request to detect and warn about the
trailing white space inserted by patches.

Signed-off-by: Nitin A Kamble <nitin.a.kamble at intel.com>
---
 scripts/create-pull-request |    8 ++++++++
 1 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/scripts/create-pull-request b/scripts/create-pull-request
index 9a8913d..9692bf1 100755
--- a/scripts/create-pull-request
+++ b/scripts/create-pull-request
@@ -229,3 +229,11 @@ Review their content, especially the summary mail:
 When you are satisfied, you can send them with:
     send-pull-request -a -p $ODIR
 EOM
+
+# Check the patches for trailing white space
+egrep -q -e "^\+.*\s+$" $ODIR/*
+if [ $? -ne 1 ]; then
+	echo
+	echo "WARNING: Trailing white space detected at these locations"
+	egrep -nH --color -e "^\+.*\s+$" $ODIR/*
+fi
-- 
1.7.3.4





More information about the Openembedded-core mailing list