From patchwork Fri Dec 9 17:27:32 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [2/5] scripts/send-pull-request: allow sending of patches without a cover letter Date: Fri, 09 Dec 2011 17:27:32 -0000 From: Otavio Salvador X-Patchwork-Id: 16571 Message-Id: <9c9a2cdfb96e8a06053e2bd3134385be4ca2a4b3.1323451575.git.otavio@ossystems.com.br> To: openembedded-core@lists.openembedded.org Signed-off-by: Otavio Salvador --- scripts/send-pull-request | 21 ++++++++++++--------- 1 files changed, 12 insertions(+), 9 deletions(-) diff --git a/scripts/send-pull-request b/scripts/send-pull-request index be13009..8d51ce2 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