Mercurial > public > mercurial-scm > hg
comparison mercurial/merge.py @ 12010:ce818cf215dc
merge with stable
author | Matt Mackall <mpm@selenic.com> |
---|---|
date | Sat, 21 Aug 2010 10:48:49 -0500 |
parents | d12fe809e1ee fad5ed0ff997 |
children | ad787252fed6 |
comparison
equal
deleted
inserted
replaced
12007:652f71b235bf | 12010:ce818cf215dc |
---|---|
268 if f == '.hgsubstate': # merged internally | 268 if f == '.hgsubstate': # merged internally |
269 continue | 269 continue |
270 repo.ui.debug("preserving %s for resolve of %s\n" % (f, fd)) | 270 repo.ui.debug("preserving %s for resolve of %s\n" % (f, fd)) |
271 fcl = wctx[f] | 271 fcl = wctx[f] |
272 fco = mctx[f2] | 272 fco = mctx[f2] |
273 fca = fcl.ancestor(fco, actx) or repo.filectx(f, fileid=nullrev) | 273 if mctx == actx: # backwards, use working dir parent as ancestor |
274 fca = fcl.parents()[0] | |
275 else: | |
276 fca = fcl.ancestor(fco, actx) | |
277 if not fca: | |
278 fca = repo.filectx(f, fileid=nullrev) | |
274 ms.add(fcl, fco, fca, fd, flags) | 279 ms.add(fcl, fco, fca, fd, flags) |
275 if f != fd and move: | 280 if f != fd and move: |
276 moves.append(f) | 281 moves.append(f) |
277 | 282 |
278 # remove renamed files after safely stored | 283 # remove renamed files after safely stored |