Mercurial > hg
comparison hgext/histedit.py @ 37314:8474005fcfe2
histedit: avoid repo.lookup() for converting revnum to nodeid
Differential Revision: https://phab.mercurial-scm.org/D3054
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Sun, 01 Apr 2018 23:29:51 -0700 |
parents | a53b87e20132 |
children | 966061b8826d |
comparison
equal
deleted
inserted
replaced
37313:70c52800940b | 37314:8474005fcfe2 |
---|---|
914 roots = list(repo.revs("roots(%ln)", outgoing.missing)) | 914 roots = list(repo.revs("roots(%ln)", outgoing.missing)) |
915 if 1 < len(roots): | 915 if 1 < len(roots): |
916 msg = _('there are ambiguous outgoing revisions') | 916 msg = _('there are ambiguous outgoing revisions') |
917 hint = _("see 'hg help histedit' for more detail") | 917 hint = _("see 'hg help histedit' for more detail") |
918 raise error.Abort(msg, hint=hint) | 918 raise error.Abort(msg, hint=hint) |
919 return repo.lookup(roots[0]) | 919 return repo[roots[0]].node() |
920 | 920 |
921 @command('histedit', | 921 @command('histedit', |
922 [('', 'commands', '', | 922 [('', 'commands', '', |
923 _('read history edits from the specified file'), _('FILE')), | 923 _('read history edits from the specified file'), _('FILE')), |
924 ('c', 'continue', False, _('continue an edit already in progress')), | 924 ('c', 'continue', False, _('continue an edit already in progress')), |