system/modules/home-manager/programs/calendar/khal.nix

27 lines
752 B
Nix

{ config, lib, ... }:
let cfg = config.local.programs.calendar; in
{
options.local.programs.calendar.khal = {
enable = lib.mkEnableOption "khal";
# Custom package doesn't work yet.
# See: https://github.com/nix-community/home-manager/pull/5428
# package = lib.mkPackageOption pkgs "khal" { };
};
config = {
programs.khal = lib.mkIf cfg.khal.enable {
enable = true;
locale = rec {
timeformat = "%H:%M";
dateformat = "%d.%m.";
longdateformat = "%d.%m.%Y";
datetimeformat = "${dateformat} ${timeformat}";
longdatetimeformat = "${longdateformat} ${timeformat}";
};
# See: https://khal.readthedocs.io/en/latest/configure.html
settings = { };
};
};
}