mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-03-25 08:55:50 +00:00
Merge remote-tracking branch 'dilyanpalauzov/meta_description'
This commit is contained in:
commit
342cb863cd
4 changed files with 29 additions and 5 deletions
|
|
@ -22,6 +22,9 @@ Note: Version 0.17 has some alpha releases but ultimately was never finalised.
|
|||
- Python 3.9 is now supported.
|
||||
- Our Debian/Ubuntu build scripts have been updated. New versions should be
|
||||
pushed to those repositories soon.
|
||||
- Add "description" and "order" as metadata. These fetch the CalDAV:
|
||||
calendar-description, CardDAV:addressbook-description and apple-ns:calendar-order
|
||||
properties.
|
||||
|
||||
Version 0.16.8
|
||||
==============
|
||||
|
|
|
|||
|
|
@ -116,10 +116,16 @@ Pair Section
|
|||
- ``metadata``: Metadata keys that should be synchronized when ``vdirsyncer
|
||||
metasync`` is executed. Example::
|
||||
|
||||
metadata = ["color", "displayname"]
|
||||
metadata = ["color", "displayname", "description", "order"]
|
||||
|
||||
This synchronizes the ``color`` and the ``displayname`` properties. The
|
||||
``conflict_resolution`` parameter applies here as well.
|
||||
This synchronizes the following properties:
|
||||
|
||||
- color: ``http://apple.com/ns/ical/:calendar-color``
|
||||
- displayname: ``DAV:displayname``
|
||||
- description: ``CalDAV:calendar-description`` and ``CardDAV:addressbook-description``
|
||||
- order: ``http://apple.com/ns/ical/:calendar-order``
|
||||
|
||||
The ``conflict_resolution`` parameter applies for these properties too.
|
||||
|
||||
.. _storage_config:
|
||||
|
||||
|
|
|
|||
|
|
@ -56,8 +56,11 @@ have any file extensions.
|
|||
known from CSS, for example) are allowed. The prefixing ``#`` must be
|
||||
present.
|
||||
|
||||
- A file called ``displayname`` contains a UTF-8 encoded label that may be used
|
||||
to represent the vdir in UIs.
|
||||
- Files called ``displayname`` and ``description`` contain a UTF-8 encoded label/
|
||||
description, that may be used to represent the vdir in UIs.
|
||||
|
||||
- A file called ``order`` inside the vdir includes the relative order
|
||||
of the calendar, a property that is only relevant in UI design.
|
||||
|
||||
Writing to vdirs
|
||||
================
|
||||
|
|
|
|||
|
|
@ -719,6 +719,8 @@ class CalDAVStorage(DAVStorage):
|
|||
_property_table.update(
|
||||
{
|
||||
"color": ("calendar-color", "http://apple.com/ns/ical/"),
|
||||
"description": ("calendar-description", "urn:ietf:params:xml:ns:caldav"),
|
||||
"order": ("calendar-order", "http://apple.com/ns/ical/"),
|
||||
}
|
||||
)
|
||||
|
||||
|
|
@ -835,3 +837,13 @@ class CardDAVStorage(DAVStorage):
|
|||
</C:addressbook-multiget>"""
|
||||
|
||||
get_multi_data_query = "{urn:ietf:params:xml:ns:carddav}address-data"
|
||||
|
||||
_property_table = dict(DAVStorage._property_table)
|
||||
_property_table.update(
|
||||
{
|
||||
"description": (
|
||||
"addressbook-description",
|
||||
"urn:ietf:params:xml:ns:carddav",
|
||||
),
|
||||
}
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue