comparison mercurial/merge.py @ 23879:b88278a308c6

localrepo: remove all external users of localrepo.wopener This change touches every module in which repository.wopener was being used, and changes it for the equivalent repository.wvfs. It should now be possible to remove localrepo.wopener.
author Angel Ezquerra <angel.ezquerra@gmail.com>
date Sun, 11 Jan 2015 01:51:52 +0100
parents 7cc77030c557
children 6becb9dbca25
comparison
equal deleted inserted replaced
23878:37a92908a382 23879:b88278a308c6
299 299
300 def _checkunknownfile(repo, wctx, mctx, f, f2=None): 300 def _checkunknownfile(repo, wctx, mctx, f, f2=None):
301 if f2 is None: 301 if f2 is None:
302 f2 = f 302 f2 = f
303 return (os.path.isfile(repo.wjoin(f)) 303 return (os.path.isfile(repo.wjoin(f))
304 and repo.wopener.audit.check(f) 304 and repo.wvfs.audit.check(f)
305 and repo.dirstate.normalize(f) not in repo.dirstate 305 and repo.dirstate.normalize(f) not in repo.dirstate
306 and mctx[f2].cmp(wctx[f])) 306 and mctx[f2].cmp(wctx[f]))
307 307
308 def _checkunknownfiles(repo, wctx, mctx, force, actions): 308 def _checkunknownfiles(repo, wctx, mctx, force, actions):
309 """ 309 """
649 yields tuples for progress updates 649 yields tuples for progress updates
650 """ 650 """
651 verbose = repo.ui.verbose 651 verbose = repo.ui.verbose
652 unlink = util.unlinkpath 652 unlink = util.unlinkpath
653 wjoin = repo.wjoin 653 wjoin = repo.wjoin
654 audit = repo.wopener.audit 654 audit = repo.wvfs.audit
655 i = 0 655 i = 0
656 for f, args, msg in actions: 656 for f, args, msg in actions:
657 repo.ui.debug(" %s: %s -> r\n" % (f, msg)) 657 repo.ui.debug(" %s: %s -> r\n" % (f, msg))
658 if verbose: 658 if verbose:
659 repo.ui.note(_("removing %s\n") % f) 659 repo.ui.note(_("removing %s\n") % f)
725 fca = repo.filectx(f1, fileid=nullrev) 725 fca = repo.filectx(f1, fileid=nullrev)
726 ms.add(fcl, fco, fca, f) 726 ms.add(fcl, fco, fca, f)
727 if f1 != f and move: 727 if f1 != f and move:
728 moves.append(f1) 728 moves.append(f1)
729 729
730 audit = repo.wopener.audit 730 audit = repo.wvfs.audit
731 _updating = _('updating') 731 _updating = _('updating')
732 _files = _('files') 732 _files = _('files')
733 progress = repo.ui.progress 733 progress = repo.ui.progress
734 734
735 # remove renamed files after safely stored 735 # remove renamed files after safely stored