Mercurial > hg-stable
diff hgext/phabricator.py @ 45135:225588c4c255
phabupdate: allow revisions to be marked with "plan changes"
Differential Revision: https://phab.mercurial-scm.org/D8751
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Wed, 15 Jul 2020 13:27:55 -0400 |
parents | 7a0a1be721a3 |
children | 1ff5070c0ab4 |
line wrap: on
line diff
--- a/hgext/phabricator.py Thu Jul 16 15:56:13 2020 +0200 +++ b/hgext/phabricator.py Wed Jul 15 13:27:55 2020 -0400 @@ -2164,6 +2164,7 @@ (b'', b'reject', False, _(b'reject revisions')), (b'', b'abandon', False, _(b'abandon revisions')), (b'', b'reclaim', False, _(b'reclaim revisions')), + (b'', b'plan-changes', False, _(b'plan changes for revisions')), (b'm', b'comment', b'', _(b'comment on the last revision')), ], _(b'DREVSPEC... [OPTIONS]'), @@ -2176,7 +2177,14 @@ DREVSPEC selects revisions. See :hg:`help phabread` for its usage. """ opts = pycompat.byteskwargs(opts) - flags = [n for n in b'accept reject abandon reclaim'.split() if opts.get(n)] + transactions = [ + b'abandon', + b'accept', + b'plan-changes', + b'reclaim', + b'reject', + ] + flags = [n for n in transactions if opts.get(n.replace(b'-', b'_'))] if len(flags) > 1: raise error.Abort(_(b'%s cannot be used together') % b', '.join(flags))