3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/nixos/modules/services/desktops/gnome/evolution-data-server.nix
pennae ef176dcf7e nixos/*: automatically convert option descriptions
conversions were done using https://github.com/pennae/nix-doc-munge
using (probably) rev f34e145 running

    nix-doc-munge nixos/**/*.nix
    nix-doc-munge --import nixos/**/*.nix

the tool ensures that only changes that could affect the generated
manual *but don't* are committed, other changes require manual review
and are discarded.
2022-08-31 16:32:53 +02:00

72 lines
1.9 KiB
Nix

# Evolution Data Server daemon.
{ config, lib, pkgs, ... }:
with lib;
{
meta = {
maintainers = teams.gnome.members;
};
# Added 2021-05-07
imports = [
(mkRenamedOptionModule
[ "services" "gnome3" "evolution-data-server" "enable" ]
[ "services" "gnome" "evolution-data-server" "enable" ]
)
(mkRenamedOptionModule
[ "services" "gnome3" "evolution-data-server" "plugins" ]
[ "services" "gnome" "evolution-data-server" "plugins" ]
)
];
###### interface
options = {
services.gnome.evolution-data-server = {
enable = mkEnableOption (lib.mdDoc "Evolution Data Server, a collection of services for storing addressbooks and calendars.");
plugins = mkOption {
type = types.listOf types.package;
default = [ ];
description = lib.mdDoc "Plugins for Evolution Data Server.";
};
};
programs.evolution = {
enable = mkEnableOption (lib.mdDoc "Evolution, a Personal information management application that provides integrated mail, calendaring and address book functionality.");
plugins = mkOption {
type = types.listOf types.package;
default = [ ];
example = literalExpression "[ pkgs.evolution-ews ]";
description = lib.mdDoc "Plugins for Evolution.";
};
};
};
###### implementation
config =
let
bundle = pkgs.evolutionWithPlugins.override { inherit (config.services.gnome.evolution-data-server) plugins; };
in
mkMerge [
(mkIf config.services.gnome.evolution-data-server.enable {
environment.systemPackages = [ bundle ];
services.dbus.packages = [ bundle ];
systemd.packages = [ bundle ];
})
(mkIf config.programs.evolution.enable {
services.gnome.evolution-data-server = {
enable = true;
plugins = [ pkgs.evolution ] ++ config.programs.evolution.plugins;
};
services.gnome.gnome-keyring.enable = true;
})
];
}