dirstate: drop workaround for '.' matching root directory
authorMartin von Zweigbergk <martinvonz@google.com>
Thu, 13 Jul 2017 23:43:16 -0700
changeset 42342 448486e12c13
parent 42341 27d6956d386b
child 42343 d8e55c0c642c
dirstate: drop workaround for '.' matching root directory The check was added in 31abcae33b4f (dirstate: do not ignore current directory '.' (issue 1078), 2008-04-05) to fix issue1078. Funnily enough, comment #2 on that issue mentions using '' instead of '.' to represent the root directory, just like my previous patch did. test-hgignore.t fails with this patch without the previous patch. Differential Revision: https://phab.mercurial-scm.org/D6402
mercurial/dirstate.py
--- a/mercurial/dirstate.py	Mon May 15 00:12:19 2017 -0700
+++ b/mercurial/dirstate.py	Thu Jul 13 23:43:16 2017 -0700
@@ -662,8 +662,6 @@
         self._dirty = False
 
     def _dirignore(self, f):
-        if f == '.':
-            return False
         if self._ignore(f):
             return True
         for p in util.finddirs(f):