comparison mercurial/cmdutil.py @ 30286:3d38a0bc774f

cmdutil: refactor checkunresolved localrepo.commit had code to check for unresolved merge conflicts, it would be helpful for at least rebase to be able to use that code without calling commit().
author timeless <timeless@mozdev.org>
date Wed, 02 Nov 2016 18:45:53 +0000
parents 144d8fe266d9
children 318a24b52eeb
comparison
equal deleted inserted replaced
30285:0fa1a41d04e4 30286:3d38a0bc774f
3401 return func 3401 return func
3402 return decorator 3402 return decorator
3403 3403
3404 return cmd 3404 return cmd
3405 3405
3406 def checkunresolved(ms):
3407 if list(ms.unresolved()):
3408 raise error.Abort(_("unresolved merge conflicts "
3409 "(see 'hg help resolve')"))
3410 if ms.mdstate() != 's' or list(ms.driverresolved()):
3411 raise error.Abort(_('driver-resolved merge conflicts'),
3412 hint=_('run "hg resolve --all" to resolve'))
3413
3406 # a list of (ui, repo, otherpeer, opts, missing) functions called by 3414 # a list of (ui, repo, otherpeer, opts, missing) functions called by
3407 # commands.outgoing. "missing" is "missing" of the result of 3415 # commands.outgoing. "missing" is "missing" of the result of
3408 # "findcommonoutgoing()" 3416 # "findcommonoutgoing()"
3409 outgoinghooks = util.hooks() 3417 outgoinghooks = util.hooks()
3410 3418