Add infrastructure for contacts and calendars#4078
Add infrastructure for contacts and calendars#4078teto merged 6 commits intonix-community:masterfrom
Conversation
This also adds the modules - programs.vdirsyncer, - programs.khal, and - services.vdirsyncer that integrate with the new infrastructure. Co-authored-by: Andrew Scott <3648487+ayyjayess@users.noreply.github.com> Co-authored-by: Sebastian Zivota <sebastian.zivota@mailbox.org> wip
1. account option `userName` is now allowed by `programs.vdirsyncer` 2. The commented out account option `userNameCommand` was required to be set by `programs.vdirsyncer` (e.g. as `null`). It is now disallowed (commented out) by vdirsyncer.
... at .../modules/programs/vdirsyncer.nix:117:38 change to listString
900bbb3 to
a86a600
Compare
|
What about #3912? |
|
#3912 is nowhere close to this old contact branch. This is much better as it generates the config for you. |
|
also just in case you are not on the chat, I actually asked on matrix before merging. To sum up it's not perfect but let's merge and make it as good as the mail infra #2335 (comment) |
|
Is there a way to exclude the new WIP modules in my local setup? That's why I would like to exclude the upstream vdirsync until its done. |
|
See https://nixos.org/manual/nixos/unstable/#sec-replace-modules |
|
@DanielSiepmann how does your module compare ? anything we could merge ?
what part do you miss, especially compared to yours ? Note that I messed up when merging. Does #4087 fix your situation ? |
|
@teto I'm so newby that my module doesn't compare at all. I just did some small hacks: https://git.daniel-siepmann.de/danielsiepmann/nixpkgs/src/branch/main/home/modules/programs/vdirsyncer.nix (module) and https://git.daniel-siepmann.de/danielsiepmann/nixpkgs/src/branch/main/home/programs/vdirsyncer.nix (config). Thanks @ncfavier. My own module has the same name, so I need to rename things or would disable my own as well? Renaming removes the need to disable the module anyway. |
|
|
|
you might be better off renaming your module, so you can try both. |
|
@teto do you mind sharing your config I can't get it running in the current state ^^ my current config is this but the accounts module dosn't create a config for vdirsyncer. { ... }:
{
services.vdirsyncer.enable = true;
accounts.contact.basePath = ".con";
accounts.calendar.basePath = ".cal";
accounts.calendar.accounts.nerdberg = {
khal = {
enable = true;
color = null;
readOnly = true;
type = "calendar";
};
local.type = "filesystem";
local.fileExt = ".ics";
name = "Nerdberg";
remote = {
type = "http";
url = "https://kalender.nerdberg.de/events.ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
};
};
} |
|
@Janik-Haag I would recommand first crafting a working configuration manually and once you have it working convert it to home-manager format so you can spot what is missing. My config is here https://github.com/teto/home/blob/main/hm/profiles/vdirsyncer.nix . could you point in the code the typo ? I am not sure if you refer to |
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: |

This also adds the modules
that integrate with the new infrastructure.
Co-authored-by: Andrew Scott 3648487+ayyjayess@users.noreply.github.com
Co-authored-by: Sebastian Zivota sebastian.zivota@mailbox.org
Description
This is a rebased version of the longstanding PR ( > 3 years ?) made to add contact and calendar support.
I've commented out "locale" support for khal since it was causing issues.
With it in its current state I was able to configure vdirsyncer and khal.
My proposition is to merge this wiht all its faults otherwise we can still wait 4 years before having anything working.
We have 6 months before release to iron things out and until then we make it clear that the module is experimental.
Checklist
Change is backwards compatible.
Code formatted with
./format.Code tested through
nix-shell --pure tests -A run.allornix develop --ignore-environment .#allusing Flakes.Test cases updated/added. See example.
Commit messages are formatted like
See CONTRIBUTING for more information and recent commit messages for examples.
If this PR adds a new module