changeset 7393:92c952c4470c

inotify: fix status . in repo.root
author Brendan Cully <brendan@kublai.com>
date Wed, 19 Nov 2008 13:00:48 -0800
parents 564326a6ef9c
children 03b60f2f90bf
files hgext/inotify/__init__.py tests/test-inotify tests/test-inotify.out
diffstat 3 files changed, 15 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/inotify/__init__.py	Wed Nov 19 13:27:57 2008 +0100
+++ b/hgext/inotify/__init__.py	Wed Nov 19 13:00:48 2008 -0800
@@ -52,6 +52,8 @@
 
         def status(self, match, ignored, clean, unknown=True):
             files = match.files()
+            if '.' in files:
+                files = [] 
             try:
                 if not ignored and not self.inotifyserver:
                     result = client.query(ui, repo, files, match, False,
--- a/tests/test-inotify	Wed Nov 19 13:27:57 2008 +0100
+++ b/tests/test-inotify	Wed Nov 19 13:00:48 2008 -0800
@@ -27,4 +27,12 @@
 echo % all
 hg status -A
 
+echo '% path patterns'
+echo x > dir/x
+hg status .
+hg status dir
+cd dir
+hg status .
+cd ..
+
 kill `cat hg.pid`
--- a/tests/test-inotify.out	Wed Nov 19 13:27:57 2008 +0100
+++ b/tests/test-inotify.out	Wed Nov 19 13:00:48 2008 -0800
@@ -27,3 +27,8 @@
 C dir/x
 C dir/y
 C e
+% path patterns
+M dir/x
+? hg.pid
+M dir/x
+M x