Show More
@@ -24,9 +24,9 b' def installnormalfilesmatchfn(manifest):' | |||||
24 | '''overrides scmutil.match so that the matcher it returns will ignore all |
|
24 | '''overrides scmutil.match so that the matcher it returns will ignore all | |
25 | largefiles''' |
|
25 | largefiles''' | |
26 | oldmatch = None # for the closure |
|
26 | oldmatch = None # for the closure | |
27 |
def override_match( |
|
27 | def override_match(ctx, pats=[], opts={}, globbed=False, | |
28 | default='relpath'): |
|
28 | default='relpath'): | |
29 |
match = oldmatch( |
|
29 | match = oldmatch(ctx, pats, opts, globbed, default) | |
30 | m = copy.copy(match) |
|
30 | m = copy.copy(match) | |
31 | notlfile = lambda f: not (lfutil.isstandin(f) or lfutil.standin(f) in |
|
31 | notlfile = lambda f: not (lfutil.isstandin(f) or lfutil.standin(f) in | |
32 | manifest) |
|
32 | manifest) | |
@@ -341,7 +341,7 b' def override_copy(orig, ui, repo, pats, ' | |||||
341 |
|
341 | |||
342 | manifest = repo[None].manifest() |
|
342 | manifest = repo[None].manifest() | |
343 | oldmatch = None # for the closure |
|
343 | oldmatch = None # for the closure | |
344 |
def override_match( |
|
344 | def override_match(ctx, pats=[], opts={}, globbed=False, | |
345 | default='relpath'): |
|
345 | default='relpath'): | |
346 | newpats = [] |
|
346 | newpats = [] | |
347 | # The patterns were previously mangled to add the standin |
|
347 | # The patterns were previously mangled to add the standin | |
@@ -351,7 +351,7 b' def override_copy(orig, ui, repo, pats, ' | |||||
351 | newpats.append(pat.replace(lfutil.shortname, '')) |
|
351 | newpats.append(pat.replace(lfutil.shortname, '')) | |
352 | else: |
|
352 | else: | |
353 | newpats.append(pat) |
|
353 | newpats.append(pat) | |
354 |
match = oldmatch( |
|
354 | match = oldmatch(ctx, newpats, opts, globbed, default) | |
355 | m = copy.copy(match) |
|
355 | m = copy.copy(match) | |
356 | lfile = lambda f: lfutil.standin(f) in manifest |
|
356 | lfile = lambda f: lfutil.standin(f) in manifest | |
357 | m._files = [lfutil.standin(f) for f in m._files if lfile(f)] |
|
357 | m._files = [lfutil.standin(f) for f in m._files if lfile(f)] | |
@@ -443,16 +443,12 b' def override_revert(orig, ui, repo, *pat' | |||||
443 | try: |
|
443 | try: | |
444 | ctx = repo[opts.get('rev')] |
|
444 | ctx = repo[opts.get('rev')] | |
445 | oldmatch = None # for the closure |
|
445 | oldmatch = None # for the closure | |
446 |
def override_match(ctx |
|
446 | def override_match(ctx, pats=[], opts={}, globbed=False, | |
447 | default='relpath'): |
|
447 | default='relpath'): | |
448 | if util.safehasattr(ctxorrepo, 'match'): |
|
448 | match = oldmatch(ctx, pats, opts, globbed, default) | |
449 | ctx0 = ctxorrepo |
|
|||
450 | else: |
|
|||
451 | ctx0 = ctxorrepo[None] |
|
|||
452 | match = oldmatch(ctxorrepo, pats, opts, globbed, default) |
|
|||
453 | m = copy.copy(match) |
|
449 | m = copy.copy(match) | |
454 | def tostandin(f): |
|
450 | def tostandin(f): | |
455 |
if lfutil.standin(f) in ctx |
|
451 | if lfutil.standin(f) in ctx or lfutil.standin(f) in ctx: | |
456 | return lfutil.standin(f) |
|
452 | return lfutil.standin(f) | |
457 | elif lfutil.standin(f) in repo[None]: |
|
453 | elif lfutil.standin(f) in repo[None]: | |
458 | return None |
|
454 | return None |
General Comments 0
You need to be logged in to leave comments.
Login now