From e1c3fd6cb8771c188f8b99d9531075bef4f59c64 Mon Sep 17 00:00:00 2001 From: Daniel Lundin Date: Wed, 27 Nov 2024 14:04:13 +0100 Subject: [PATCH] ghostty+nvim: Add oled mode for darker darks on laptop --- home/common/default.nix | 1 + home/common/ghostty.nix | 10 ++++++---- home/common/nvim/dieter/lua/dieter/init.lua | 2 +- home/dln/dinky.nix | 4 ++++ 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/home/common/default.nix b/home/common/default.nix index 3a2a686..e66ef79 100644 --- a/home/common/default.nix +++ b/home/common/default.nix @@ -19,4 +19,5 @@ ]; options.patagia.desktop.enable = lib.mkEnableOption "Desktop environment"; + options.patagia.oled.enable = lib.mkEnableOption "Darker darks on oled screens"; } diff --git a/home/common/ghostty.nix b/home/common/ghostty.nix index ecb79c3..d0842e5 100644 --- a/home/common/ghostty.nix +++ b/home/common/ghostty.nix @@ -63,10 +63,12 @@ }; }; - xdg.configFile."ghostty/themes/PatagiaDark".text = '' - # background = "#14151a" - # foreground = "#d1d5db" - background = "#000000" + xdg.configFile."ghostty/themes/PatagiaDark".text = + let + background = if config.patagia.oled.enable then "#000000" else "#14151a"; + in + '' + background = "${background}" foreground = "#d1d5db" cursor-color = #00d992 selection-background = #d7d7d7 diff --git a/home/common/nvim/dieter/lua/dieter/init.lua b/home/common/nvim/dieter/lua/dieter/init.lua index 243c8bf..0e39bd7 100644 --- a/home/common/nvim/dieter/lua/dieter/init.lua +++ b/home/common/nvim/dieter/lua/dieter/init.lua @@ -39,7 +39,7 @@ local colors = { }, dark = { - background = hsl(230, 13, 9), + background = "NONE", foreground = hsl(216, 12, 84), accent1 = hsl(12, 100, 50), diff --git a/home/dln/dinky.nix b/home/dln/dinky.nix index ba0b79e..fd47c55 100644 --- a/home/dln/dinky.nix +++ b/home/dln/dinky.nix @@ -5,6 +5,10 @@ ./desktop.nix ]; + patagia = { + oled.enable = true; + }; + dconf.settings = { "org/gnome/shell" = { enabled-extensions = [ "Battery-Health-Charging@maniacx.github.com" ];