diff options
author | Konstantin Ryabitsev <konstantin@linuxfoundation.org> | 2021-10-19 17:34:17 -0400 |
---|---|---|
committer | Konstantin Ryabitsev <konstantin@linuxfoundation.org> | 2021-10-19 17:34:17 -0400 |
commit | 6a212b5524903c170d420763c9c08a5444745281 (patch) | |
tree | 305c879817044b12b43bf916c20b50ff28418ef8 /b4/command.py | |
parent | a57ec40ef6d57b5aea62fbd1c814175d1da3fd23 (diff) | |
download | b4-6a212b5524903c170d420763c9c08a5444745281.tar.gz |
Initial implementation of native mail sending
I'm felling comfortable that "b4 ty" is sufficiently mature at this
point to implement sending thank-yous directly. This is only the initial
implementation that covers only the very basic parts of git's sendemail
configuration options, but this should actually cover 90% of cases if
not more.
One important caveat -- I moved the "b4 ty -s" flag to be "b4 ty -t" in
order to disambiguate it from the capital -S (that actually does the
sending). Since "b4 ty" is still marked as an experimental feature, I
feel we can do this without much impact.
Signed-off-by: Konstantin Ryabitsev <konstantin@linuxfoundation.org>
Diffstat (limited to 'b4/command.py')
-rw-r--r-- | b4/command.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/b4/command.py b/b4/command.py index 199d0c2..9d364dd 100644 --- a/b4/command.py +++ b/b4/command.py @@ -199,7 +199,7 @@ def cmd(): help='Write thanks files into this dir (default=.)') sp_ty.add_argument('-l', '--list', action='store_true', default=False, help='List pull requests and patch series you have retrieved') - sp_ty.add_argument('-s', '--send', default=None, + sp_ty.add_argument('-t', '--thank-for', default=None, help='Generate thankyous for specific entries from -l (e.g.: 1,3-5,7-; or "all")') sp_ty.add_argument('-d', '--discard', default=None, help='Discard specific messages from -l (e.g.: 1,3-5,7-; or "all")') @@ -209,6 +209,10 @@ def cmd(): help='The branch to check against, instead of current') sp_ty.add_argument('--since', default='1.week', help='The --since option to use when auto-matching patches (default=1.week)') + sp_ty.add_argument('-S', '--send-email', action='store_true', dest='sendemail', default=False, + help='Send email instead of writing out .thanks files') + sp_ty.add_argument('--dry-run', action='store_true', dest='dryrun', default=False, + help='Print out emails instead of sending them') sp_ty.set_defaults(func=cmd_ty) # b4 diff |