--- a/hgext3rd/evolve/__init__.py Tue Jul 02 10:17:42 2019 +0200
+++ b/hgext3rd/evolve/__init__.py Sun Jun 30 23:50:57 2019 +0530
@@ -1355,14 +1355,26 @@
@eh.uisetup
def setupevolveunfinished(ui):
- data = ('evolvestate', False, False, _('evolve in progress'),
- _("use 'hg evolve --continue' or 'hg evolve --abort' to abort"))
- cmdutil.unfinishedstates.append(data)
+ if not util.safehasattr(cmdutil, 'unfinishedstates'):
+ from mercurial import state as statemod
+ _msg = _('To continue: hg evolve --continue\n'
+ 'To abort: hg evolve --abort\n'
+ 'To stop: hg evolve --stop\n'
+ '(also see `hg help evolve.interrupted`)')
+ statemod.addunfinished('evolve', fname='evolvestate',
+ continueflag=True, stopflag=True,
+ statushint=_msg)
+ statemod.addunfinished('pick', fname='pickstate', continueflag=True)
+ else:
+ # compat <= hg-5.0 (5f2f6912c9e6)
+ data = ('evolvestate', False, False, _('evolve in progress'),
+ _("use 'hg evolve --continue' or 'hg evolve --abort' to abort"))
+ cmdutil.unfinishedstates.append(data)
- afterresolved = ('evolvestate', _('hg evolve --continue'))
- pickresolved = ('pickstate', _('hg pick --continue'))
- cmdutil.afterresolvedstates.append(afterresolved)
- cmdutil.afterresolvedstates.append(pickresolved)
+ afterresolved = ('evolvestate', _('hg evolve --continue'))
+ pickresolved = ('pickstate', _('hg pick --continue'))
+ cmdutil.afterresolvedstates.append(afterresolved)
+ cmdutil.afterresolvedstates.append(pickresolved)
if util.safehasattr(cmdutil, 'STATES'):
statedata = ('evolve', cmdutil.fileexistspredicate('evolvestate'),