##// END OF EJS Templates
largefiles: split the creation of a normal matcher out of its install method...
Matt Harbison -
r23428:b5e3f3d2 default
parent child Browse files
Show More
@@ -22,11 +22,7 import basestore
22 22
23 23 # -- Utility functions: commonly/repeatedly needed functionality ---------------
24 24
25 def installnormalfilesmatchfn(manifest):
26 '''installmatchfn with a matchfn that ignores all largefiles'''
27 def overridematch(ctx, pats=[], opts={}, globbed=False,
28 default='relpath'):
29 match = oldmatch(ctx, pats, opts, globbed, default)
25 def composenormalfilematcher(match, manifest):
30 26 m = copy.copy(match)
31 27 notlfile = lambda f: not (lfutil.isstandin(f) or lfutil.standin(f) in
32 28 manifest)
@@ -36,6 +32,13 def installnormalfilesmatchfn(manifest):
36 32 origmatchfn = m.matchfn
37 33 m.matchfn = lambda f: notlfile(f) and origmatchfn(f)
38 34 return m
35
36 def installnormalfilesmatchfn(manifest):
37 '''installmatchfn with a matchfn that ignores all largefiles'''
38 def overridematch(ctx, pats=[], opts={}, globbed=False,
39 default='relpath'):
40 match = oldmatch(ctx, pats, opts, globbed, default)
41 return composenormalfilematcher(match, manifest)
39 42 oldmatch = installmatchfn(overridematch)
40 43
41 44 def installmatchfn(f):
General Comments 0
You need to be logged in to leave comments. Login now