1# An example configuration for vdirsyncer.
2#
3# Move it to ~/.vdirsyncer/config or ~/.config/vdirsyncer/config and edit it.
4# Run `vdirsyncer --help` for CLI usage.
5#
6# Optional parameters are commented out.
7# This file doesn't document all available parameters, see
8# http://vdirsyncer.pimutils.org/ for the rest of them.
9
10[general]
11# A folder where vdirsyncer can store some metadata about each pair.
12status_path = "~/.config/vdirsyncer/status/"
13
14# CARDDAV
15[pair contacts]
16# A `[pair <name>]` block defines two storages `a` and `b` that should be
17# synchronized. The definition of these storages follows in `[storage <name>]`
18# blocks. This is similar to accounts in OfflineIMAP.
19a = "contacts_local"
20b = "contacts_remote"
21
22# Synchronize all collections that can be found.
23# You need to run `vdirsyncer discover` if new calendars/addressbooks are added
24# on the server.
25
26collections = ["from a", "from b"]
27
28# Synchronize the "display name" property into a local file (~/.contacts/displayname).
29metadata = ["displayname"]
30
31# To resolve a conflict the following values are possible:
32# `null` - abort when collisions occur (default)
33# `"a wins"` - assume a's items to be more up-to-date
34# `"b wins"` - assume b's items to be more up-to-date
35conflict_resolution = "b wins"
36
37[storage contacts_local]
38# A storage references actual data on a remote server or on the local disk.
39# Similar to repositories in OfflineIMAP.
40type = "filesystem"
41path = "~/.contacts/"
42fileext = ".vcf"
43
44[storage contacts_remote]
45type = "carddav"
46url = "{{- onepasswordRead "op://Private/dav-url/password" -}}"
47username = "amolith"
48password.fetch = ["command", "op", "read", "op://Private/vdirsyncer/password"]
49
50# CALDAV
51[pair calendar]
52a = "calendar_local"
53b = "calendar_remote"
54collections = ["from a", "from b"]
55
56# Calendars also have a color property
57metadata = ["displayname", "color"]
58
59# To resolve a conflict the following values are possible:
60# `null` - abort when collisions occur (default)
61# `"a wins"` - assume a's items to be more up-to-date
62# `"b wins"` - assume b's items to be more up-to-date
63conflict_resolution = "b wins"
64
65[storage calendar_local]
66type = "filesystem"
67path = "~/.calendars/"
68fileext = ".ics"
69
70[storage calendar_remote]
71type = "caldav"
72url = "{{- onepasswordRead "op://Private/dav-url/password" -}}"
73username = "amolith"
74password.fetch = ["command", "op", "read", "op://Private/vdirsyncer/password"]