From 326ef69d1296cd35a86d1eaee0741e6fc956af52 Mon Sep 17 00:00:00 2001 From: Otavio Salvador Date: Wed, 7 Dec 2011 21:19:52 +0000 Subject: scripts/send-pull-request: allow sending of patches without a cover letter Signed-off-by: Otavio Salvador --- scripts/send-pull-request | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'scripts') diff --git a/scripts/send-pull-request b/scripts/send-pull-request index be130096c..8d51ce2ec 100755 --- a/scripts/send-pull-request +++ b/scripts/send-pull-request @@ -108,15 +108,18 @@ fi # Verify the cover letter is complete and free of tokens -CL="$PDIR/0000-cover-letter.patch" -for TOKEN in SUBJECT BLURB; do - grep -q "*** $TOKEN HERE ***" "$CL" - if [ $? -eq 0 ]; then - echo "ERROR: Please edit $CL and try again (Look for '*** $TOKEN HERE ***')." - exit 1 - fi -done - +if [ -e $PDIR/0000-cover-letter.patch ]; then + CL="$PDIR/0000-cover-letter.patch" + for TOKEN in SUBJECT BLURB; do + grep -q "*** $TOKEN HERE ***" "$CL" + if [ $? -eq 0 ]; then + echo "ERROR: Please edit $CL and try again (Look for '*** $TOKEN HERE ***')." + exit 1 + fi + done +else + echo "WARNING: No cover letter will be send." +fi # Harvest emails from the generated patches and populate AUTO_CC. if [ $AUTO_CL -eq 1 ]; then -- cgit v1.2.3