##// END OF EJS Templates
revert: add a way for external extensions to prefetch file data...
Pierre-Yves David -
r22370:45e02cfa default
parent child Browse files
Show More
@@ -2527,6 +2527,9 b' def revert(ui, repo, ctx, parents, *pats'
2527 (unknown, actions['unknown'], discard),
2527 (unknown, actions['unknown'], discard),
2528 )
2528 )
2529
2529
2530 needdata = ('revert', 'add', 'remove', 'undelete')
2531 _revertprefetch(repo, ctx, *[actions[name][0] for name in needdata])
2532
2530 for abs, (rel, exact) in sorted(names.items()):
2533 for abs, (rel, exact) in sorted(names.items()):
2531 # target file to be touch on disk (relative to cwd)
2534 # target file to be touch on disk (relative to cwd)
2532 target = repo.wjoin(abs)
2535 target = repo.wjoin(abs)
@@ -2564,6 +2567,10 b' def revert(ui, repo, ctx, parents, *pats'
2564 finally:
2567 finally:
2565 wlock.release()
2568 wlock.release()
2566
2569
2570 def _revertprefetch(repo, ctx, *files):
2571 """Let extension changing the storage layer prefetch content"""
2572 pass
2573
2567 def _performrevert(repo, parents, ctx, actions):
2574 def _performrevert(repo, parents, ctx, actions):
2568 """function that actually perform all the actions computed for revert
2575 """function that actually perform all the actions computed for revert
2569
2576
General Comments 0
You need to be logged in to leave comments. Login now