]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
don't recurse into directories that start with '.'
authorBenjamin Peterson <benjamin@python.org>
Wed, 15 Oct 2008 20:34:09 +0000 (20:34 +0000)
committerBenjamin Peterson <benjamin@python.org>
Wed, 15 Oct 2008 20:34:09 +0000 (20:34 +0000)
Tools/scripts/reindent.py

index 65749f0be53ab86b1fcbfa8d2940fd84062db2d2..3e9affb9c511b924f117244ee21a11db417eb7b7 100755 (executable)
@@ -99,7 +99,8 @@ def check(file):
         for name in names:
             fullname = os.path.join(file, name)
             if ((recurse and os.path.isdir(fullname) and
-                 not os.path.islink(fullname))
+                 not os.path.islink(fullname) and
+                 not os.path.split(fullname)[1].startswith("."))
                 or name.lower().endswith(".py")):
                 check(fullname)
         return