mirror of
https://github.com/nix-community/home-manager.git
synced 2025-12-15 21:41:09 +01:00
treewide: format with latest stable formatter
Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
This commit is contained in:
parent
56ee5d0670
commit
b4752b0eda
56 changed files with 816 additions and 832 deletions
|
|
@ -65,29 +65,28 @@ let
|
|||
};
|
||||
in
|
||||
toIni {
|
||||
"Account ${name}" =
|
||||
{
|
||||
localrepository = "${name}-local";
|
||||
remoterepository = "${name}-remote";
|
||||
}
|
||||
// postSyncHook
|
||||
// offlineimap.extraConfig.account;
|
||||
"Account ${name}" = {
|
||||
localrepository = "${name}-local";
|
||||
remoterepository = "${name}-remote";
|
||||
}
|
||||
// postSyncHook
|
||||
// offlineimap.extraConfig.account;
|
||||
|
||||
"Repository ${name}-local" = {
|
||||
type = localType;
|
||||
localfolders = account.maildir.absPath;
|
||||
} // offlineimap.extraConfig.local;
|
||||
}
|
||||
// offlineimap.extraConfig.local;
|
||||
|
||||
"Repository ${name}-remote" =
|
||||
{
|
||||
type = remoteType;
|
||||
remoteuser = account.userName;
|
||||
}
|
||||
// remoteHost
|
||||
// remotePort
|
||||
// remotePassEval
|
||||
// ssl
|
||||
// offlineimap.extraConfig.remote;
|
||||
"Repository ${name}-remote" = {
|
||||
type = remoteType;
|
||||
remoteuser = account.userName;
|
||||
}
|
||||
// remoteHost
|
||||
// remotePort
|
||||
// remotePassEval
|
||||
// ssl
|
||||
// offlineimap.extraConfig.remote;
|
||||
};
|
||||
|
||||
extraConfigType = with lib.types; attrsOf (either (either str int) bool);
|
||||
|
|
@ -189,30 +188,31 @@ in
|
|||
''
|
||||
}/bin/get_settings.pyc";
|
||||
|
||||
xdg.configFile."offlineimap/config".text =
|
||||
''
|
||||
# Generated by Home Manager.
|
||||
# See https://github.com/OfflineIMAP/offlineimap/blob/master/offlineimap.conf
|
||||
# for an exhaustive list of options.
|
||||
''
|
||||
+ toIni (
|
||||
{
|
||||
general = {
|
||||
accounts = lib.concatMapStringsSep "," (a: a.name) accounts;
|
||||
pythonfile = "${config.xdg.configHome}/offlineimap/get_settings.py";
|
||||
metadata = "${config.xdg.dataHome}/offlineimap";
|
||||
} // cfg.extraConfig.general;
|
||||
xdg.configFile."offlineimap/config".text = ''
|
||||
# Generated by Home Manager.
|
||||
# See https://github.com/OfflineIMAP/offlineimap/blob/master/offlineimap.conf
|
||||
# for an exhaustive list of options.
|
||||
''
|
||||
+ toIni (
|
||||
{
|
||||
general = {
|
||||
accounts = lib.concatMapStringsSep "," (a: a.name) accounts;
|
||||
pythonfile = "${config.xdg.configHome}/offlineimap/get_settings.py";
|
||||
metadata = "${config.xdg.dataHome}/offlineimap";
|
||||
}
|
||||
// lib.optionalAttrs (cfg.extraConfig.mbnames != { }) {
|
||||
mbnames = {
|
||||
enabled = true;
|
||||
} // cfg.extraConfig.mbnames;
|
||||
// cfg.extraConfig.general;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.extraConfig.mbnames != { }) {
|
||||
mbnames = {
|
||||
enabled = true;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.extraConfig.default != { }) {
|
||||
DEFAULT = cfg.extraConfig.default;
|
||||
}
|
||||
)
|
||||
+ "\n"
|
||||
+ lib.concatStringsSep "\n" (map accountStr accounts);
|
||||
// cfg.extraConfig.mbnames;
|
||||
}
|
||||
// lib.optionalAttrs (cfg.extraConfig.default != { }) {
|
||||
DEFAULT = cfg.extraConfig.default;
|
||||
}
|
||||
)
|
||||
+ "\n"
|
||||
+ lib.concatStringsSep "\n" (map accountStr accounts);
|
||||
};
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue