Mercurial > hg
view mercurial/mergeutil.py @ 45325:c6eea5804551
commitctx: extract sidedata encoding inside its own function
This part of the code is quite independent from the rest. Thank to the new
ChangingFiles object, moving with the rest of the sidedata code (in metadata.py)
is simple.
The changelog.add method is simply passing the `files` object to the new
function. It will be easy to increase/change the data we gather and encode
without impacting the changelog method.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Sat, 25 Jul 2020 16:02:26 +0200 |
parents | 8ff1ecfadcd1 |
children | 32ce4cbaec4b |
line wrap: on
line source
# mergeutil.py - help for merge processing in mercurial # # Copyright 2005-2007 Matt Mackall <mpm@selenic.com> # # This software may be used and distributed according to the terms of the # GNU General Public License version 2 or any later version. from __future__ import absolute_import from .i18n import _ from . import error def checkunresolved(ms): if list(ms.unresolved()): raise error.Abort( _(b"unresolved merge conflicts (see 'hg help resolve')") ) if ms.mdstate() != b's' or list(ms.driverresolved()): raise error.Abort( _(b'driver-resolved merge conflicts'), hint=_(b'run "hg resolve --all" to resolve'), )