Openembedded Core Discussions
 help / color / mirror / Atom feed
* [Patch v2 0/1] Misc: check trailing white space in the patches
@ 2012-12-05 23:47 nitin.a.kamble
  2012-12-05 23:47 ` [Patch v2 1/1] create-pull-request: detect trailing white space nitin.a.kamble
  0 siblings, 1 reply; 2+ messages in thread
From: nitin.a.kamble @ 2012-12-05 23:47 UTC (permalink / raw)
  To: Openembedded-core, yocto

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

The earlier (v1) patch was checking trailing white space only for added empty lines.
This v2 patch checks for all the lines added by patches.

Thanks,
Nitin

The following changes since commit 381c4b69c7e8b452f4d3de2f8214e6e5f6a9abe7:

  sstate.bbclass: fix detection of owners matching sstate files (2012-12-05 15:34:07 +0000)

are available in the git repository at:
  git://git.pokylinux.org/poky-contrib nitin/misc
  http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=nitin/misc

Nitin A Kamble (1):
  create-pull-request: detect trailing white space

 scripts/create-pull-request |   13 ++++++++++++-
 1 files changed, 12 insertions(+), 1 deletions(-)

-- 
1.7.3.4




^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Patch v2 1/1] create-pull-request: detect trailing white space
  2012-12-05 23:47 [Patch v2 0/1] Misc: check trailing white space in the patches nitin.a.kamble
@ 2012-12-05 23:47 ` nitin.a.kamble
  0 siblings, 0 replies; 2+ messages in thread
From: nitin.a.kamble @ 2012-12-05 23:47 UTC (permalink / raw)
  To: Openembedded-core, yocto

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

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

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

diff --git a/scripts/create-pull-request b/scripts/create-pull-request
index 9a8913d..58e7df1 100755
--- a/scripts/create-pull-request
+++ b/scripts/create-pull-request
@@ -173,7 +173,6 @@ mkdir $ODIR
 # Generate the patches and cover letter
 git format-patch -M40 --subject-prefix="$PREFIX" -n -o $ODIR --thread=shallow --cover-letter $RELATIVE_TO..$COMMIT_ID > /dev/null
 
-
 # Customize the cover letter
 CL="$ODIR/0000-cover-letter.patch"
 PM="$ODIR/pull-msg"
@@ -229,3 +228,15 @@ 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
+echo
+egrep -nH -e "^\+.*\s+$" $ODIR/* > /dev/null
+if [ $? -ne 1 ]; then
+	echo "WARNING: Trailing white space detected at these locations"
+	egrep -nH -e "^\+.*\s+$" $ODIR/*
+else
+	echo "Note: No trailing white space is detected in these patches :)"
+fi
+
+
-- 
1.7.3.4




^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-12-06  0:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-05 23:47 [Patch v2 0/1] Misc: check trailing white space in the patches nitin.a.kamble
2012-12-05 23:47 ` [Patch v2 1/1] create-pull-request: detect trailing white space nitin.a.kamble

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox