##// END OF EJS Templates
merge: pass wctx to batchremove and batchget...
Phil Cohen -
r33081:6582dc01 default
parent child Browse files
Show More
@@ -1078,7 +1078,7 b' def calculateupdates(repo, wctx, mctx, a'
1078
1078
1079 return actions, diverge, renamedelete
1079 return actions, diverge, renamedelete
1080
1080
1081 def batchremove(repo, actions):
1081 def batchremove(repo, wctx, actions):
1082 """apply removes to the working directory
1082 """apply removes to the working directory
1083
1083
1084 yields tuples for progress updates
1084 yields tuples for progress updates
@@ -1122,7 +1122,7 b' def batchremove(repo, actions):'
1122 "(consider changing to repo root: %s)\n") %
1122 "(consider changing to repo root: %s)\n") %
1123 repo.root)
1123 repo.root)
1124
1124
1125 def batchget(repo, mctx, actions):
1125 def batchget(repo, mctx, wctx, actions):
1126 """apply gets to the working directory
1126 """apply gets to the working directory
1127
1127
1128 mctx is the context to get from
1128 mctx is the context to get from
@@ -1222,14 +1222,16 b' def applyupdates(repo, actions, wctx, mc'
1222
1222
1223 # remove in parallel (must come first)
1223 # remove in parallel (must come first)
1224 z = 0
1224 z = 0
1225 prog = worker.worker(repo.ui, 0.001, batchremove, (repo,), actions['r'])
1225 prog = worker.worker(repo.ui, 0.001, batchremove, (repo, wctx),
1226 actions['r'])
1226 for i, item in prog:
1227 for i, item in prog:
1227 z += i
1228 z += i
1228 progress(_updating, z, item=item, total=numupdates, unit=_files)
1229 progress(_updating, z, item=item, total=numupdates, unit=_files)
1229 removed = len(actions['r'])
1230 removed = len(actions['r'])
1230
1231
1231 # get in parallel
1232 # get in parallel
1232 prog = worker.worker(repo.ui, 0.001, batchget, (repo, mctx), actions['g'])
1233 prog = worker.worker(repo.ui, 0.001, batchget, (repo, mctx, wctx),
1234 actions['g'])
1233 for i, item in prog:
1235 for i, item in prog:
1234 z += i
1236 z += i
1235 progress(_updating, z, item=item, total=numupdates, unit=_files)
1237 progress(_updating, z, item=item, total=numupdates, unit=_files)
General Comments 0
You need to be logged in to leave comments. Login now