##// END OF EJS Templates
cat: replace match.bad() monkey patching with match.badmatch()...
Matt Harbison -
r25438:7ce5a323 default
parent child Browse files
Show More
@@ -2437,22 +2437,16 b' def cat(ui, repo, ctx, matcher, prefix, '
2437 2437 return 0
2438 2438
2439 2439 # Don't warn about "missing" files that are really in subrepos
2440 bad = matcher.bad
2441
2442 2440 def badfn(path, msg):
2443 2441 for subpath in ctx.substate:
2444 2442 if path.startswith(subpath):
2445 2443 return
2446 bad(path, msg)
2447
2448 matcher.bad = badfn
2449
2450 for abs in ctx.walk(matcher):
2444 matcher.bad(path, msg)
2445
2446 for abs in ctx.walk(matchmod.badmatch(matcher, badfn)):
2451 2447 write(abs)
2452 2448 err = 0
2453 2449
2454 matcher.bad = bad
2455
2456 2450 for subpath in sorted(ctx.substate):
2457 2451 sub = ctx.sub(subpath)
2458 2452 try:
General Comments 0
You need to be logged in to leave comments. Login now