The options API has been updated, in order for a more flexible setup with `local.modules.desktop.enable` being replaced with an enum of desktops at `local.systemVars.desktop`, which allows for switching desktop environments by changing a single option. This is so that we can switch to cosmic and only enable the programs we need (i.e. disable greetd because we use cosmic-greeter and enable terminals since that is desktop related). This is simpler than having a different module per desktop.
31 lines
793 B
Nix
31 lines
793 B
Nix
{
|
|
lib,
|
|
pkgs,
|
|
config,
|
|
...
|
|
}: let
|
|
inherit (config.local.systemVars) username;
|
|
toZathura = attrs:
|
|
builtins.concatStringsSep "\n"
|
|
(lib.mapAttrsToList (option: value: "set ${option} \"${toString value}\"") attrs);
|
|
in {
|
|
config = lib.mkIf (config.local.systemVars.desktop != "none") {
|
|
hjem.users.${username} = {
|
|
packages = [pkgs.zathura];
|
|
files = {
|
|
".config/zathura/zathurarc".text = toZathura {
|
|
font = "sans-serif 12";
|
|
selection-notification = true;
|
|
|
|
selection-clipboard = "clipboard";
|
|
adjust-open = "best-fit";
|
|
pages-per-row = "1";
|
|
scroll-page-aware = "true";
|
|
scroll-full-overlap = "0.01";
|
|
scroll-step = "100";
|
|
zoom-min = "10";
|
|
};
|
|
};
|
|
};
|
|
};
|
|
}
|