hgext/largefiles/overrides.py
changeset 16093 7e30f5f2285f
parent 16075 d2e8e79a6361
child 16094 0776a6cababe
equal deleted inserted replaced
16092:914bc95e227b 16093:7e30f5f2285f
   263 # in a file 'foo' if we already have a largefile with the same name.
   263 # in a file 'foo' if we already have a largefile with the same name.
   264 #
   264 #
   265 # The overridden function filters the unknown files by removing any
   265 # The overridden function filters the unknown files by removing any
   266 # largefiles. This makes the merge proceed and we can then handle this
   266 # largefiles. This makes the merge proceed and we can then handle this
   267 # case further in the overridden manifestmerge function below.
   267 # case further in the overridden manifestmerge function below.
   268 def override_checkunknown(origfn, wctx, mctx, folding):
   268 def override_checkunknownfile(origfn, repo, wctx, mctx, f):
   269     origunknown = wctx.unknown()
   269     if lfutil.standin(f) in wctx:
   270     wctx._unknown = filter(lambda f: lfutil.standin(f) not in wctx, origunknown)
   270         return False
   271     try:
   271     return origfn(repo, wctx, mctx, f)
   272         return origfn(wctx, mctx, folding)
       
   273     finally:
       
   274         wctx._unknown = origunknown
       
   275 
   272 
   276 # The manifest merge handles conflicts on the manifest level. We want
   273 # The manifest merge handles conflicts on the manifest level. We want
   277 # to handle changes in largefile-ness of files at this level too.
   274 # to handle changes in largefile-ness of files at this level too.
   278 #
   275 #
   279 # The strategy is to run the original manifestmerge and then process
   276 # The strategy is to run the original manifestmerge and then process