summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ac6d696)
raw | patch | inline | side by side (parent: ac6d696)
author | stefan <stefan@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Mon, 9 Feb 2009 17:47:12 +0000 (17:47 +0000) | ||
committer | stefan <stefan@57a73879-2fb5-44c3-a270-3262357dd7e2> | |
Mon, 9 Feb 2009 17:47:12 +0000 (17:47 +0000) |
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/roundup/trunk@4117 57a73879-2fb5-44c3-a270-3262357dd7e2
roundup/init.py | patch | blob | history | |
run_tests.py | patch | blob | history |
diff --git a/roundup/init.py b/roundup/init.py
index 8506f22aefee3dbc20dfd435d5391e1a93dd2a7b..7ecba91ef516ad7d261a828aa6e6dfd9f8dd374b 100644 (file)
--- a/roundup/init.py
+++ b/roundup/init.py
def copytree(src, dst, symlinks=0):
"""Recursively copy a directory tree using copyDigestedFile().
- The destination directory os allowed to exist.
+ The destination directory is allowed to exist.
If the optional symlinks flag is true, symbolic links in the
source tree result in symbolic links in the destination tree; if
This was copied from shutil.py in std lib.
"""
- names = os.listdir(src)
+
+ # Prevent 'hidden' files (those starting with '.') from being considered.
+ names = [f for f in os.listdir(src) if not f.startswith('.')]
try:
os.mkdir(dst)
except OSError, error:
diff --git a/run_tests.py b/run_tests.py
index c54375307b4a3a055751d0708a1ec52efc0b3009..d84f5901b12c62b25b44d3486f19c76be9246bf5 100644 (file)
--- a/run_tests.py
+++ b/run_tests.py
cycles in your Zope sandbox, so don't do that.
"""
try:
- names = os.listdir(top)
+ # Prevent 'hidden' files (those starting with '.') from being considered.
+ names = [f for f in os.listdir(top) if not f.startswith('.')]
except os.error:
return
func(arg, top, names)