Show More
@@ -77,7 +77,7 b' def matchpats(repo, pats=[], opts={}, he' | |||||
77 | return util.cmdmatcher(repo.root, cwd, pats or ['.'], opts.get('include'), |
|
77 | return util.cmdmatcher(repo.root, cwd, pats or ['.'], opts.get('include'), | |
78 | opts.get('exclude'), head) |
|
78 | opts.get('exclude'), head) | |
79 |
|
79 | |||
80 | def makewalk(repo, pats, opts, node=None, head='', badmatch=None): |
|
80 | def makewalk(repo, pats=[], opts={}, node=None, head='', badmatch=None): | |
81 | files, matchfn, anypats = matchpats(repo, pats, opts, head) |
|
81 | files, matchfn, anypats = matchpats(repo, pats, opts, head) | |
82 | exact = dict(zip(files, files)) |
|
82 | exact = dict(zip(files, files)) | |
83 | def walk(): |
|
83 | def walk(): | |
@@ -86,12 +86,12 b' def makewalk(repo, pats, opts, node=None' | |||||
86 | yield src, fn, util.pathto(repo.getcwd(), fn), fn in exact |
|
86 | yield src, fn, util.pathto(repo.getcwd(), fn), fn in exact | |
87 | return files, matchfn, walk() |
|
87 | return files, matchfn, walk() | |
88 |
|
88 | |||
89 | def walk(repo, pats, opts, node=None, head='', badmatch=None): |
|
89 | def walk(repo, pats=[], opts={}, node=None, head='', badmatch=None): | |
90 | files, matchfn, results = makewalk(repo, pats, opts, node, head, badmatch) |
|
90 | files, matchfn, results = makewalk(repo, pats, opts, node, head, badmatch) | |
91 | for r in results: |
|
91 | for r in results: | |
92 | yield r |
|
92 | yield r | |
93 |
|
93 | |||
94 | def addremove(repo, pats, opts={}, wlock=None, dry_run=None): |
|
94 | def addremove(repo, pats=[], opts={}, wlock=None, dry_run=None): | |
95 | if dry_run is None: |
|
95 | if dry_run is None: | |
96 | dry_run = opts.get('dry_run') |
|
96 | dry_run = opts.get('dry_run') | |
97 | add, remove = [], [] |
|
97 | add, remove = [], [] |
General Comments 0
You need to be logged in to leave comments.
Login now