Show More
@@ -253,7 +253,7 b' def perfmergecalculate(ui, repo, rev, **' | |||
|
253 | 253 | # acceptremote is True because we don't want prompts in the middle of |
|
254 | 254 | # our benchmark |
|
255 | 255 | merge.calculateupdates(repo, wctx, rctx, [ancestor], False, False, |
|
256 |
|
|
|
256 | acceptremote=True, followcopies=True) | |
|
257 | 257 | timer(d) |
|
258 | 258 | fm.end() |
|
259 | 259 | |
@@ -679,4 +679,3 b' def perflrucache(ui, size=4, gets=10000,' | |||
|
679 | 679 | timer, fm = gettimer(ui, opts) |
|
680 | 680 | timer(fn, title=title) |
|
681 | 681 | fm.end() |
|
682 |
@@ -192,7 +192,6 b' class mercurial_sink(converter_sink):' | |||
|
192 | 192 | self.repo, p1ctx, p2ctx, anc, |
|
193 | 193 | True, # branchmerge |
|
194 | 194 | True, # force |
|
195 | False, # partial | |
|
196 | 195 | False, # acceptremote |
|
197 | 196 | False, # followcopies |
|
198 | 197 | ) |
@@ -458,11 +458,11 b' def overridecheckunknownfile(origfn, rep' | |||
|
458 | 458 | # writing the files into the working copy and lfcommands.updatelfiles |
|
459 | 459 | # will update the largefiles. |
|
460 | 460 | def overridecalculateupdates(origfn, repo, p1, p2, pas, branchmerge, force, |
|
461 |
|
|
|
461 | acceptremote, followcopies, matcher=None): | |
|
462 | 462 | overwrite = force and not branchmerge |
|
463 | 463 | actions, diverge, renamedelete = origfn( |
|
464 |
repo, p1, p2, pas, branchmerge, force, |
|
|
465 | followcopies) | |
|
464 | repo, p1, p2, pas, branchmerge, force, acceptremote, | |
|
465 | followcopies, matcher=matcher) | |
|
466 | 466 | |
|
467 | 467 | if overwrite: |
|
468 | 468 | return actions, diverge, renamedelete |
@@ -841,9 +841,13 b' def _resolvetrivial(repo, wctx, mctx, an' | |||
|
841 | 841 | # remote did change but ended up with same content |
|
842 | 842 | del actions[f] # don't get = keep local deleted |
|
843 | 843 | |
|
844 |
def calculateupdates(repo, wctx, mctx, ancestors, branchmerge, force, |
|
|
845 | acceptremote, followcopies): | |
|
844 | def calculateupdates(repo, wctx, mctx, ancestors, branchmerge, force, | |
|
845 | acceptremote, followcopies, matcher=None): | |
|
846 | 846 | "Calculate the actions needed to merge mctx into wctx using ancestors" |
|
847 | if matcher is None or matcher.always(): | |
|
848 | partial = False | |
|
849 | else: | |
|
850 | partial = matcher.matchfn | |
|
847 | 851 | |
|
848 | 852 | if len(ancestors) == 1: # default |
|
849 | 853 | actions, diverge, renamedelete = manifestmerge( |
@@ -1414,13 +1418,9 b' def update(repo, node, branchmerge, forc' | |||
|
1414 | 1418 | followcopies = True |
|
1415 | 1419 | |
|
1416 | 1420 | ### calculate phase |
|
1417 | if matcher is None or matcher.always(): | |
|
1418 | partial = False | |
|
1419 | else: | |
|
1420 | partial = matcher.matchfn | |
|
1421 | 1421 | actionbyfile, diverge, renamedelete = calculateupdates( |
|
1422 |
repo, wc, p2, pas, branchmerge, force, |
|
|
1423 | followcopies) | |
|
1422 | repo, wc, p2, pas, branchmerge, force, mergeancestor, | |
|
1423 | followcopies, matcher=matcher) | |
|
1424 | 1424 | # Convert to dictionary-of-lists format |
|
1425 | 1425 | actions = dict((m, []) for m in 'a am f g cd dc r dm dg m e k'.split()) |
|
1426 | 1426 | for f, (m, args, msg) in actionbyfile.iteritems(): |
General Comments 0
You need to be logged in to leave comments.
Login now