mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-04-27 14:57:41 +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.
|
- Fix crash of Google storages when saving token file.
|
||||||
- Make DAV discovery more RFC-conformant, see :ghpr:`585`.
|
- Make DAV discovery more RFC-conformant, see :ghpr:`585`.
|
||||||
- Vdirsyncer is now tested against Xandikos, see :ghpr:`601`.
|
- 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
|
- Statuses are now stored in a sqlite database. Old data is automatically
|
||||||
migrated. Users with really large datasets should encounter performance
|
migrated. Users with really large datasets should encounter performance
|
||||||
improvements. This means that **sqlite3 is now a dependency of vdirsyncer**.
|
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
|
Can be used with `khal <http://lostpackets.de/khal/>`_. See :doc:`vdir` for
|
||||||
a more formal description of the format.
|
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
|
:param path: Absolute path to a vdir/collection. If this is used in
|
||||||
combination with the ``collections`` parameter in a pair-section, this
|
combination with the ``collections`` parameter in a pair-section, this
|
||||||
should point to a directory of vdirs instead.
|
should point to a directory of vdirs instead.
|
||||||
|
|
@ -72,9 +75,7 @@ class FilesystemStorage(Storage):
|
||||||
def _validate_collection(cls, path):
|
def _validate_collection(cls, path):
|
||||||
if not os.path.isdir(path):
|
if not os.path.isdir(path):
|
||||||
return False
|
return False
|
||||||
for item in os.listdir(path):
|
if os.path.basename(path).startswith('.'):
|
||||||
item_path = os.path.join(path, item)
|
|
||||||
if os.path.isdir(item_path):
|
|
||||||
return False
|
return False
|
||||||
return True
|
return True
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue