mirror of
https://github.com/nix-community/home-manager.git
synced 2025-11-21 17:59:39 +01:00
Reduce maintenance burden and increase efficiency by automatically importing modules following a specific convention. Co-authored-by: awwpotato <awwpotato@voidq.com> Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
53 lines
1.1 KiB
Nix
53 lines
1.1 KiB
Nix
{ lib, ... }:
|
|
let
|
|
inherit (lib) mkOption types;
|
|
|
|
extraConfigType = with types; attrsOf (either (either str int) bool);
|
|
in
|
|
{
|
|
options.offlineimap = {
|
|
enable = lib.mkEnableOption "OfflineIMAP";
|
|
|
|
extraConfig.account = mkOption {
|
|
type = extraConfigType;
|
|
default = { };
|
|
example = {
|
|
autorefresh = 20;
|
|
};
|
|
description = ''
|
|
Extra configuration options to add to the account section.
|
|
'';
|
|
};
|
|
|
|
extraConfig.local = mkOption {
|
|
type = extraConfigType;
|
|
default = { };
|
|
example = {
|
|
sync_deletes = true;
|
|
};
|
|
description = ''
|
|
Extra configuration options to add to the local account
|
|
section.
|
|
'';
|
|
};
|
|
|
|
extraConfig.remote = mkOption {
|
|
type = extraConfigType;
|
|
default = { };
|
|
example = {
|
|
maxconnections = 2;
|
|
expunge = false;
|
|
};
|
|
description = ''
|
|
Extra configuration options to add to the remote account
|
|
section.
|
|
'';
|
|
};
|
|
|
|
postSyncHookCommand = mkOption {
|
|
type = types.lines;
|
|
default = "";
|
|
description = "Command to run after fetching new mails.";
|
|
};
|
|
};
|
|
}
|