Show More
@@ -571,8 +571,8 b' def overridecalculateupdates(' | |||||
571 |
|
571 | |||
572 | for lfile in sorted(lfiles): |
|
572 | for lfile in sorted(lfiles): | |
573 | standin = lfutil.standin(lfile) |
|
573 | standin = lfutil.standin(lfile) | |
574 |
(lm, largs, lmsg) = mresult. |
|
574 | (lm, largs, lmsg) = mresult.getfile(lfile, (None, None, None)) | |
575 |
(sm, sargs, smsg) = mresult. |
|
575 | (sm, sargs, smsg) = mresult.getfile(standin, (None, None, None)) | |
576 | if sm in (b'g', b'dc') and lm != b'r': |
|
576 | if sm in (b'g', b'dc') and lm != b'r': | |
577 | if sm == b'dc': |
|
577 | if sm == b'dc': | |
578 | f1, f2, fa, move, anc = sargs |
|
578 | f1, f2, fa, move, anc = sargs |
@@ -454,7 +454,8 b' def checkpathconflicts(repo, wctx, mctx,' | |||||
454 | # A file is in a directory which aliases a local file. |
|
454 | # A file is in a directory which aliases a local file. | |
455 | # We will need to rename the local file. |
|
455 | # We will need to rename the local file. | |
456 | localconflicts.add(p) |
|
456 | localconflicts.add(p) | |
457 | if p in mresult.actions and mresult.actions[p][0] in ( |
|
457 | pd = mresult.getfile(p) | |
|
458 | if pd and pd[0] in ( | |||
458 | mergestatemod.ACTION_CREATED, |
|
459 | mergestatemod.ACTION_CREATED, | |
459 | mergestatemod.ACTION_DELETED_CHANGED, |
|
460 | mergestatemod.ACTION_DELETED_CHANGED, | |
460 | mergestatemod.ACTION_MERGE, |
|
461 | mergestatemod.ACTION_MERGE, | |
@@ -489,7 +490,7 b' def checkpathconflicts(repo, wctx, mctx,' | |||||
489 | ctxname = bytes(mctx).rstrip(b'+') |
|
490 | ctxname = bytes(mctx).rstrip(b'+') | |
490 | for f, p in _filesindirs(repo, mf, remoteconflicts): |
|
491 | for f, p in _filesindirs(repo, mf, remoteconflicts): | |
491 | if f not in deletedfiles: |
|
492 | if f not in deletedfiles: | |
492 |
m, args, msg = mresult. |
|
493 | m, args, msg = mresult.getfile(p) | |
493 | pnew = util.safename( |
|
494 | pnew = util.safename( | |
494 | p, ctxname, wctx, set(mresult.actions.keys()) |
|
495 | p, ctxname, wctx, set(mresult.actions.keys()) | |
495 | ) |
|
496 | ) | |
@@ -612,6 +613,14 b' class mergeresult(object):' | |||||
612 | self._filemapping[filename] = (action, data, message) |
|
613 | self._filemapping[filename] = (action, data, message) | |
613 | self._actionmapping[action][filename] = (data, message) |
|
614 | self._actionmapping[action][filename] = (data, message) | |
614 |
|
615 | |||
|
616 | def getfile(self, filename, default_return=None): | |||
|
617 | """ returns (action, args, msg) about this file | |||
|
618 | ||||
|
619 | returns default_return if the file is not present """ | |||
|
620 | if filename in self._filemapping: | |||
|
621 | return self._filemapping[filename] | |||
|
622 | return default_return | |||
|
623 | ||||
615 | def removefile(self, filename): |
|
624 | def removefile(self, filename): | |
616 | """ removes a file from the mergeresult object as the file might |
|
625 | """ removes a file from the mergeresult object as the file might | |
617 | not merging anymore """ |
|
626 | not merging anymore """ | |
@@ -1960,9 +1969,10 b' def update(' | |||||
1960 | # Prompt and create actions. Most of this is in the resolve phase |
|
1969 | # Prompt and create actions. Most of this is in the resolve phase | |
1961 | # already, but we can't handle .hgsubstate in filemerge or |
|
1970 | # already, but we can't handle .hgsubstate in filemerge or | |
1962 | # subrepoutil.submerge yet so we have to keep prompting for it. |
|
1971 | # subrepoutil.submerge yet so we have to keep prompting for it. | |
1963 | if b'.hgsubstate' in mresult.actions: |
|
1972 | vals = mresult.getfile(b'.hgsubstate') | |
|
1973 | if vals: | |||
1964 | f = b'.hgsubstate' |
|
1974 | f = b'.hgsubstate' | |
1965 |
m, args, msg = |
|
1975 | m, args, msg = vals | |
1966 | prompts = filemerge.partextras(labels) |
|
1976 | prompts = filemerge.partextras(labels) | |
1967 | prompts[b'f'] = f |
|
1977 | prompts[b'f'] = f | |
1968 | if m == mergestatemod.ACTION_CHANGED_DELETED: |
|
1978 | if m == mergestatemod.ACTION_CHANGED_DELETED: |
General Comments 0
You need to be logged in to leave comments.
Login now