This commit is contained in:
2026-07-12 15:25:55 -03:00
commit 29377d0c9a
160 changed files with 6138 additions and 0 deletions
+240
View File
@@ -0,0 +1,240 @@
{
inputs,
lib,
config,
pkgs,
...
}:
{
accounts = {
calendar = {
basePath = "${config.home.homeDirectory}/.calendars";
accounts = {
inbox = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/3a35411d-3b32-854e-9a57-1cca5510fd8e/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "light blue";
};
};
avodah = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/f3901be0-8dca-7856-d1cb-fe7869e92c1e/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "light red";
};
};
casa = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/4f26caba-3134-4253-cdb6-16d34df2a109/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "dark red";
};
};
exercicio = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/773de611-4f21-053f-e916-f48f1b3f0e24/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "dark green";
};
};
familia = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/4fb446ab-33a1-1a91-c009-5b69316c8cea/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "dark blue";
};
};
saude = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/4b455515-de59-2bdb-9e51-aee5a1a2d960/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "light magenta";
};
};
teleo = {
remote = {
type = "caldav";
url = "https://cal.joaoporta.com/jpporta/dd52bfd0-c8c4-2d7b-6469-25244f69fe3a/";
userName = "jpporta";
passwordCommand = [
"pass"
"show"
"personal/caldav"
];
};
local = {
type = "filesystem";
fileExt = ".ics";
};
vdirsyncer = {
enable = true;
collections = null;
conflictResolution = "remote wins";
metadata = [
"color"
"displayname"
];
};
khal = {
enable = true;
type = "calendar";
color = "yellow";
};
};
};
};
};
}
+41
View File
@@ -0,0 +1,41 @@
{
inputs,
lib,
config,
pkgs,
...
}:
{
imports = [
./accounts.nix
];
options.custom = {
jpporta-calendars.enable = lib.mkEnableOption "enable personal jpporta calendars";
};
config = lib.mkIf config.custom.jpporta-calendars.enable {
programs = {
vdirsyncer.enable = true;
khal = {
enable = true;
locale = {
timeformat = "%H:%M";
dateformat = "%Y-%m-%d";
longdateformat = "%Y-%m-%d";
datetimeformat = "%Y-%m-%d %H:%M";
longdatetimeformat = "%Y-%m-%d %H:%M";
};
};
};
services.vdirsyncer = {
enable = true;
frequency = "*:0/15"; # every 15 minutes; systemd OnCalendar format
};
};
}