30 if cwd: |
30 if cwd: |
31 return [util.normpath(os.path.join(cwd, x)) for x in args] |
31 return [util.normpath(os.path.join(cwd, x)) for x in args] |
32 return args |
32 return args |
33 |
33 |
34 def matchpats(repo, cwd, pats=[], opts={}, head=''): |
34 def matchpats(repo, cwd, pats=[], opts={}, head=''): |
35 return util.matcher(repo.root, cwd, pats or ['.'], opts.get('include'), |
35 return util.cmdmatcher(repo.root, cwd, pats or ['.'], opts.get('include'), |
36 opts.get('exclude'), head) |
36 opts.get('exclude'), head) |
37 |
37 |
38 def makewalk(repo, pats, opts, head=''): |
38 def makewalk(repo, pats, opts, head=''): |
39 cwd = repo.getcwd() |
39 cwd = repo.getcwd() |
40 files, matchfn, anypats = matchpats(repo, cwd, pats, opts, head) |
40 files, matchfn, anypats = matchpats(repo, cwd, pats, opts, head) |