mercurial/cmdutil.py
changeset 4195 e8ee8fdeddb1
parent 4186 08d31e43592a
child 4197 492d0d5b6976
--- a/mercurial/cmdutil.py	Sat Mar 10 23:00:55 2007 -0300
+++ b/mercurial/cmdutil.py	Sat Mar 10 23:00:57 2007 -0300
@@ -127,15 +127,16 @@
                               pathname),
                 mode)
 
-def matchpats(repo, pats=[], opts={}, head='', globbed=False):
+def matchpats(repo, pats=[], opts={}, head='', globbed=False, default=None):
     cwd = repo.getcwd()
     return util.cmdmatcher(repo.root, cwd, pats or [], opts.get('include'),
-                           opts.get('exclude'), head, globbed=globbed)
+                           opts.get('exclude'), head, globbed=globbed,
+                           default=default)
 
 def walk(repo, pats=[], opts={}, node=None, head='', badmatch=None,
-         globbed=False):
+         globbed=False, default=None):
     files, matchfn, anypats = matchpats(repo, pats, opts, head,
-                                        globbed=globbed)
+                                        globbed=globbed, default=default)
     exact = dict.fromkeys(files)
     for src, fn in repo.walk(node=node, files=files, match=matchfn,
                              badmatch=badmatch):