nixos-config/home/bat.nix

29 lines
410 B
Nix
Raw Normal View History

2022-04-10 11:54:58 +02:00
{
config,
lib,
...
}: let
inherit
(lib)
2022-01-11 16:08:21 +01:00
mkEnableOption
mkIf
2022-04-10 11:54:58 +02:00
;
2022-01-11 16:08:21 +01:00
2021-07-29 00:07:33 +02:00
cfg = config.my.home.bat;
batTheme = config.my.theme.batTheme;
2022-04-10 11:54:58 +02:00
in {
2022-01-11 16:08:21 +01:00
options.my.home.bat = {
2022-04-10 11:54:58 +02:00
enable = (mkEnableOption "bat code display tool") // {default = true;};
2021-07-29 00:07:33 +02:00
};
2022-01-11 16:08:21 +01:00
config = mkIf cfg.enable {
2021-07-29 00:07:33 +02:00
programs.bat = {
enable = true;
config = {
theme = batTheme.name;
};
};
};
}