X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?p=topgit.git;a=blobdiff_plain;f=tg-mail.sh;h=24e5f67b2742b8edf6fd6213f58d6546a27e013c;hp=7e394b894cc630bf01fcef92fc09956aaed87a77;hb=3c01cd2fe990d94651758ca858dd6ee326e73f7b;hpb=8db01713f1f45ae38066b9da307e90eda40c43c8 diff --git a/tg-mail.sh b/tg-mail.sh index 7e394b8..24e5f67 100644 --- a/tg-mail.sh +++ b/tg-mail.sh @@ -3,6 +3,7 @@ # GPLv2 name= +send_email_args= ## Parse options @@ -10,8 +11,10 @@ name= while [ -n "$1" ]; do arg="$1"; shift case "$arg" in + -s) + send_email_args="$1"; shift;; -*) - echo "Usage: tg [...] mail [NAME]" >&2 + echo "Usage: tg [...] mail [-s SEND_EMAIL_ARGS] [NAME]" >&2 exit 1;; *) [ -z "$name" ] || die "name already specified ($name)" @@ -45,6 +48,6 @@ people=() # NOTE: git-send-email handles cc itself -git send-email "${people[@]}" "$patchfile" +git send-email $send_email_args "${people[@]}" "$patchfile" rm "$patchfile"