From 4d76e2da7ccd5e3440605fe4560f6a038873ce23 Mon Sep 17 00:00:00 2001 From: Bernardo Meurer Date: Tue, 10 Oct 2023 05:46:25 -0400 Subject: [PATCH] Avoid IFD in bat module (#158) --- modules/bat/hm.nix | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/modules/bat/hm.nix b/modules/bat/hm.nix index fd154730..80be228e 100644 --- a/modules/bat/hm.nix +++ b/modules/bat/hm.nix @@ -1,17 +1,14 @@ { pkgs, config, lib, ... }: -let - themeFile = config.lib.stylix.colors { - template = ./base16-stylix.mustache; - extension = ".tmTheme"; - }; -in { options.stylix.targets.bat.enable = config.lib.stylix.mkEnableTarget "Bat" config.programs.bat.enable; config = lib.mkIf config.stylix.targets.bat.enable { - programs.bat.themes."base16-stylix" = builtins.readFile themeFile; + programs.bat.themes."base16-stylix".src = config.lib.stylix.colors { + template = ./base16-stylix.mustache; + extension = ".tmTheme"; + }; home.sessionVariables.BAT_THEME = "base16-stylix"; }; }