From: Nitin A Kamble <nitin.a.kam...@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.kam...@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..c35c427 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 _______________________________________________ yocto mailing list yocto@yoctoproject.org https://lists.yoctoproject.org/listinfo/yocto