473 # consistent with "hg export" output. |
473 # consistent with "hg export" output. |
474 _metanamemap = util.sortdict([(r'user', 'User'), (r'date', 'Date'), |
474 _metanamemap = util.sortdict([(r'user', 'User'), (r'date', 'Date'), |
475 (r'node', 'Node ID'), (r'parent', 'Parent ')]) |
475 (r'node', 'Node ID'), (r'parent', 'Parent ')]) |
476 |
476 |
477 def _confirmbeforesend(repo, revs): |
477 def _confirmbeforesend(repo, revs): |
|
478 url, token = readurltoken(repo) |
478 ui = repo.ui |
479 ui = repo.ui |
479 for rev in revs: |
480 for rev in revs: |
480 ctx = repo[rev] |
481 ctx = repo[rev] |
481 desc = ctx.description().splitlines()[0] |
482 desc = ctx.description().splitlines()[0] |
482 ui.write(('%d: ' % rev), label='phabsend.revnumber') |
483 ui.write(('%d: ' % rev), label='phabsend.revnumber') |
483 ui.write(('%s\n' % desc), label='phabsend.desc') |
484 ui.write(('%s\n' % desc), label='phabsend.desc') |
484 |
485 |
485 if ui.promptchoice(_('Phabsend the above changes (yn)?' |
486 if ui.promptchoice(_('Send the above changes to %s (yn)?' |
486 '$$ &Yes $$ &No')): |
487 '$$ &Yes $$ &No') % url): |
487 return False |
488 return False |
488 |
489 |
489 return True |
490 return True |
490 |
491 |
491 _knownstatusnames = {'accepted', 'needsreview', 'needsrevision', 'closed', |
492 _knownstatusnames = {'accepted', 'needsreview', 'needsrevision', 'closed', |