aboutsummaryrefslogtreecommitdiffstats
path: root/modules/terminal/bat/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'modules/terminal/bat/default.nix')
-rw-r--r--modules/terminal/bat/default.nix26
1 files changed, 26 insertions, 0 deletions
diff --git a/modules/terminal/bat/default.nix b/modules/terminal/bat/default.nix
new file mode 100644
index 0000000..3c962a3
--- /dev/null
+++ b/modules/terminal/bat/default.nix
@@ -0,0 +1,26 @@
+{
+ config,
+ lib,
+ pkgs,
+ ...
+}:
+
+# bat - a cat clone with wings
+{
+ config = lib.mkIf config.programs.bat.enable {
+ programs.bat = {
+ config = {
+ theme = "base16";
+ };
+ themes = {
+ base16 = {
+ src = pkgs.runCommand "bat-base16-theme" { } ''
+ mkdir -p $out
+ cp ${config.scheme { template = ./base16.mustache.tmTheme; }} $out/base16.tmTheme
+ '';
+ file = "base16.tmTheme";
+ };
+ };
+ };
+ };
+}