2023-03-27 17:32:26 -07:00
|
|
|
{
|
2024-10-19 11:24:15 -07:00
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}: let
|
|
|
|
inherit (config.rose-pine) sources;
|
|
|
|
cfg = config.programs.bat.rose-pine;
|
|
|
|
enable = cfg.enable && config.programs.bat.enable;
|
|
|
|
themeName =
|
|
|
|
if (cfg.flavor == "main")
|
|
|
|
then "rose-pine"
|
|
|
|
else "rose-pine-${cfg.flavor}";
|
|
|
|
in {
|
|
|
|
options.programs.bat.rose-pine = lib.rp.mkRosePineOpt {name = "bat";};
|
2023-03-27 15:49:50 -07:00
|
|
|
|
2023-11-02 10:55:47 -07:00
|
|
|
config = lib.mkIf enable {
|
|
|
|
programs.bat = {
|
|
|
|
config.theme = themeName;
|
|
|
|
|
|
|
|
themes.${themeName} = {
|
2024-10-19 11:24:15 -07:00
|
|
|
src = sources.tm-theme;
|
|
|
|
file = "dist/themes/${themeName}.tmTheme";
|
2023-10-13 07:51:17 -07:00
|
|
|
};
|
2023-03-27 15:49:50 -07:00
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|