Add pyc/pyo to ignore list for inventory directories

Fixes #7308
pull/7315/merge
James Cammarata 11 years ago
parent 21f8c0bc96
commit 393124e462

@ -39,14 +39,9 @@ class InventoryDirectory(object):
for i in self.names: for i in self.names:
if i.endswith("~") or i.endswith(".orig") or i.endswith(".bak"): # Skip files that end with certain extensions or characters
continue for ext in ("~", ".orig", ".bak", ".ini", ".retry", ".pyc", ".pyo"):
if i.endswith(".ini"): if i.endswith(ext):
# configuration file for an inventory script
continue
if i.endswith(".retry"):
# this file is generated on a failed playbook and should only be
# used when run specifically
continue continue
# Skip hidden files # Skip hidden files
if i.startswith('.') and not i.startswith('./'): if i.startswith('.') and not i.startswith('./'):

Loading…
Cancel
Save