mercurial/commands.py
changeset 4200 b5d1eaade333
parent 4182 ba51a8225a60
parent 4196 1c69c73d85d9
child 4202 b2873c587b1a
--- a/mercurial/commands.py	Sat Mar 10 17:45:32 2007 -0800
+++ b/mercurial/commands.py	Sat Mar 10 23:21:33 2007 -0300
@@ -1599,9 +1599,8 @@
     Print all files under Mercurial control whose names match the
     given patterns.
 
-    This command searches the current directory and its
-    subdirectories.  To search an entire repository, move to the root
-    of the repository.
+    This command searches the entire repository by default.  To search
+    just the current directory and its subdirectories, use "--include .".
 
     If no patterns are given to match, this command prints all file
     names.
@@ -1618,14 +1617,18 @@
     else:
         node = None
 
+    ret = 1
     for src, abs, rel, exact in cmdutil.walk(repo, pats, opts, node=node,
-                                             head='(?:.*/|)'):
+                                             default='relglob'):
         if not node and repo.dirstate.state(abs) == '?':
             continue
         if opts['fullpath']:
             ui.write(os.path.join(repo.root, abs), end)
         else:
             ui.write(((pats and rel) or abs), end)
+        ret = 0
+
+    return ret
 
 def log(ui, repo, *pats, **opts):
     """show revision history of entire repository or files