snowflake/user/docs.nix
2025-06-02 22:28:14 +08:00

45 lines
849 B
Nix

{ config, pkgs, lib, ... }:
let
cfg = config.docs;
in
{
imports = [ ./subs/sioyek.nix ];
options.docs = {
zathura.enable = lib.mkOption {
default = true;
type = lib.types.bool;
};
sioyek.enable = lib.mkOption {
default = true;
type = lib.types.bool;
};
libreoffice.enable = lib.mkOption {
default = true;
type = lib.types.bool;
};
foliate.enable = lib.mkOption {
default = true;
type = lib.types.bool;
};
};
config = {
subs.sioyek.enable = cfg.sioyek.enable;
programs.zathura = {
enable = cfg.zathura.enable;
extraConfig = builtins.readFile ../config/zathurarc;
};
programs.foliate = {
enable = cfg.foliate.enable;
};
home.packages = lib.mkIf cfg.libreoffice.enable [
pkgs.libreoffice-fresh
];
};
}