From patchwork Mon May 16 22:26:14 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [RFC,v2,14/15] send-pull-request: streamline git-send-email usage Date: Mon, 16 May 2011 22:26:14 -0000 From: Darren Hart X-Patchwork-Id: 4205 Message-Id: <442f31a687cb0362e9e0a3492eed6bb4ad5d8366.1305584418.git.dvhart@linux.intel.com> To: openembedded-core@lists.openembedded.org The script was sending one patch at a time, which defeats the internal confirmation mechanism of git-send-email (which would otherwise allow the user to send all patches or abort immediately). Rework the sending logic to use no more than two commands. Use two commands when the cover letter is to be sent to all recipients with the -a argument. Otherwise, send all patches via the same command. The script duplicates git's send confirmation, eliminate that. Signed-off-by: Darren Hart Reported-by: Khem Raj Cc: Khem Raj Cc: Joshua Lock Acked-by: Joshua Lock --- scripts/send-pull-request | 68 +++++++++++++++++--------------------------- 1 files changed, 26 insertions(+), 42 deletions(-) diff --git a/scripts/send-pull-request b/scripts/send-pull-request index 21eb302..8d0bd34 100755 --- a/scripts/send-pull-request +++ b/scripts/send-pull-request @@ -1,6 +1,7 @@ #!/bin/bash AUTO=0 AUTO_CL=0 +GITSOBCC="" # Prevent environment leakage to these vars. unset TO @@ -59,10 +60,11 @@ while getopts "achp:t:" OPT; do case $OPT in a) AUTO_CL=1 - AUTO=1 - ;; + # Fall through to include -c + ;& c) AUTO=1 + GITSOBCC="--signed-off-by-cc" ;; h) usage @@ -130,48 +132,30 @@ if [ -z "$TO" ] && [ -z "$AUTO_CC" ]; then fi -# Generate report for the user and require confirmation before sending -cat <