From 99b5ec88778ae382f8c39fc85b878bdffd31b87f Mon Sep 17 00:00:00 2001 From: Guanran Wang Date: Sun, 3 Dec 2023 19:56:30 +0800 Subject: [PATCH] home, xresources: import colorscheme from tokyonight package --- .../device-type/graphical/nixos/theme.nix | 38 ++++--------------- 1 file changed, 7 insertions(+), 31 deletions(-) diff --git a/users/guanranwang/home-manager/profiles/device-type/graphical/nixos/theme.nix b/users/guanranwang/home-manager/profiles/device-type/graphical/nixos/theme.nix index a1be232..eddde85 100644 --- a/users/guanranwang/home-manager/profiles/device-type/graphical/nixos/theme.nix +++ b/users/guanranwang/home-manager/profiles/device-type/graphical/nixos/theme.nix @@ -66,11 +66,8 @@ }; # Misc - xresources.properties = lib.mkMerge [ - { - # Cursor - "Xcursor.theme" = "Adwaita"; - + xresources = { + properties = { # Fonts "Xft.autohint" = "0"; "Xft.lcdfilter" = "lcddefault"; @@ -78,30 +75,9 @@ "Xft.hinting" = "1"; "Xft.antialias" = "1"; "Xft.rgba" = "rgb"; - } - (lib.mkIf (config.myFlake.home-manager.colorScheme == "tokyonight") { - # Tokyonight color scheme - # i have no idea what does it apply to - "*background" = "#1a1b26"; - "*foreground" = "#c0caf5"; - - "*color0" = "#15161e"; - "*color1" = "#f7768e"; - "*color2" = "#9ece6a"; - "*color3" = "#e0af68"; - "*color4" = "#7aa2f7"; - "*color5" = "#bb9af7"; - "*color6" = "#7dcfff"; - "*color7" = "#a9b1d6"; - - "*color8" = "#414868"; - "*color9" = "#f7768e"; - "*color10" = "#9ece6a"; - "*color11" = "#e0af68"; - "*color12" = "#7aa2f7"; - "*color13" = "#bb9af7"; - "*color14" = "#7dcfff"; - "*color15" = "#c0caf5"; - }) - ]; + }; + extraConfig = + lib.mkIf (config.myFlake.home-manager.colorScheme == "tokyonight") + (builtins.readFile "${pkgs.vimPlugins.tokyonight-nvim}/extras/xresources/tokyonight_night.Xresources"); + }; }