Rev3176, Skip listing ignored directories on signing

This commit is contained in:
shortcutme 2017-12-20 23:25:25 +01:00
parent adbf787bd4
commit c7d067ea3c
No known key found for this signature in database
GPG key ID: 5B63BAE6CB9613AE
3 changed files with 25 additions and 7 deletions

View file

@ -512,14 +512,12 @@ class ContentManager(object):
ignored = True
self.log.error("- [ERROR] Only ascii encoded directories allowed: %s" % dir_inner_path)
for file_relative_path in self.site.storage.walk(dir_inner_path):
for file_relative_path in self.site.storage.walk(dir_inner_path, ignore_pattern):
file_name = helper.getFilename(file_relative_path)
ignored = optional = False
if file_name == "content.json":
ignored = True
elif ignore_pattern and SafeRe.match(ignore_pattern, file_relative_path):
ignored = True
elif file_name.startswith(".") or file_name.endswith("-old") or file_name.endswith("-new"):
ignored = True
elif not self.isValidRelativePath(file_relative_path):