# decsync-vdir Synchronises [DecSync](https://github.com/39aldo39/DecSync) contacts/calendars with a [vdir](https://vdirsyncer.pimutils.org/en/stable/vdir.html). ## Usage Make sure you have Go 1.16 or later installed. **Please back up your DecSync directory and vdir before trying decsync-vdir in case something goes wrong!** Building decsync-vdir: ``` $ go build decsync-vdir.go ``` Syncing a contacts directory with DecSync: ``` $ ./decsync-vdir /path/to/decsync/contacts/ /path/to/vdir .vcf ``` Syncing a calendar directory with DecSync: ``` $ ./decsync-vdir /path/to/decsync/calendars/ /path/to/vdir .ics ``` The vdir directory will be created if it doesn't already exist. ## Limitations - Deleting a file in the vdir will not delete it on DecSync, `decsync-vdir` will recreate the file inside the vdir instead. - `decsync-vdir` doesn't store entries created on other devices in its own storage directory under `v2`. This means that you shouldn't delete other device's directories manually after running decsync-vdir.