mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-03-25 08:55:50 +00:00
Ignore directories with leading dot
This commit is contained in:
parent
fbe3f9910d
commit
dad9fd8904
2 changed files with 7 additions and 4 deletions
|
|
@ -16,6 +16,8 @@ Version 0.16.0
|
|||
- Fix crash of Google storages when saving token file.
|
||||
- Make DAV discovery more RFC-conformant, see :ghpr:`585`.
|
||||
- Vdirsyncer is now tested against Xandikos, see :ghpr:`601`.
|
||||
- Subfolders with a leading dot are now ignored during discover for
|
||||
``filesystem`` storage.
|
||||
- Statuses are now stored in a sqlite database. Old data is automatically
|
||||
migrated. Users with really large datasets should encounter performance
|
||||
improvements. This means that **sqlite3 is now a dependency of vdirsyncer**.
|
||||
|
|
|
|||
|
|
@ -23,6 +23,9 @@ class FilesystemStorage(Storage):
|
|||
Can be used with `khal <http://lostpackets.de/khal/>`_. See :doc:`vdir` for
|
||||
a more formal description of the format.
|
||||
|
||||
Directories with a leading dot are ignored to make usage of e.g. version
|
||||
control easier.
|
||||
|
||||
:param path: Absolute path to a vdir/collection. If this is used in
|
||||
combination with the ``collections`` parameter in a pair-section, this
|
||||
should point to a directory of vdirs instead.
|
||||
|
|
@ -72,10 +75,8 @@ class FilesystemStorage(Storage):
|
|||
def _validate_collection(cls, path):
|
||||
if not os.path.isdir(path):
|
||||
return False
|
||||
for item in os.listdir(path):
|
||||
item_path = os.path.join(path, item)
|
||||
if os.path.isdir(item_path):
|
||||
return False
|
||||
if os.path.basename(path).startswith('.'):
|
||||
return False
|
||||
return True
|
||||
|
||||
@classmethod
|
||||
|
|
|
|||
Loading…
Reference in a new issue