summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-05-17 12:43:48 -0700
committerZac Medico <zmedico@gentoo.org>2011-05-17 12:43:48 -0700
commit8c1ef09c17168325e92483034767ef89c696e2d3 (patch)
tree93d33292c035b836ac0c6a49178208fda29db8dc
parentda3cdf8a6ffd5cd69587291d75d19f1deb0e5976 (diff)
downloadportage-8c1ef09c17168325e92483034767ef89c696e2d3.tar.gz
portage-8c1ef09c17168325e92483034767ef89c696e2d3.tar.bz2
portage-8c1ef09c17168325e92483034767ef89c696e2d3.zip
--autounmask-write: don't write hidden files
-rw-r--r--pym/_emerge/depgraph.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/pym/_emerge/depgraph.py b/pym/_emerge/depgraph.py
index a2b953448..609b4d580 100644
--- a/pym/_emerge/depgraph.py
+++ b/pym/_emerge/depgraph.py
@@ -34,6 +34,7 @@ from portage.util import ConfigProtect, shlex_split, new_protect_filename
from portage.util import cmp_sort_key, writemsg, writemsg_stdout
from portage.util import writemsg_level, write_atomic
from portage.util.digraph import digraph
+from portage.util.listdir import _ignorecvs_dirs
from portage.versions import catpkgsplit
from _emerge.AtomArg import AtomArg
@@ -5697,6 +5698,8 @@ class depgraph(object):
if stat.S_ISREG(st.st_mode):
last_file_path = p
elif stat.S_ISDIR(st.st_mode):
+ if os.path.basename(p) in _ignorecvs_dirs:
+ continue
try:
contents = os.listdir(p)
except OSError:
@@ -5704,6 +5707,9 @@ class depgraph(object):
else:
contents.sort(reverse=True)
for child in contents:
+ if child.startswith(".") or \
+ child.endswith("~"):
+ continue
stack.append(os.path.join(p, child))
return last_file_path