From d8ffd94212c5e9554e3b2eea1edeaa394c458b87 Mon Sep 17 00:00:00 2001 From: atagen Date: Sun, 21 May 2023 03:06:20 +1000 Subject: [PATCH] holy carp rose pine --- home/home.nix | 34 +++++++++++++++++++++++++--------- pkgs/default.nix | 6 ++++-- pkgs/rose-pine-icons.nix | 35 +++++++++++++++++++++++++++++++++++ pkgs/rose-pine-theme.nix | 10 +++++----- rice.nix | 20 ++++++++++---------- system/configuration.nix | 4 ++-- 6 files changed, 81 insertions(+), 28 deletions(-) create mode 100644 pkgs/rose-pine-icons.nix diff --git a/home/home.nix b/home/home.nix index 242a0df..6c6f542 100644 --- a/home/home.nix +++ b/home/home.nix @@ -59,7 +59,7 @@ in { meslo-lgs-nf - libsForQt5.qtstyleplugin-kvantum + # libsForQt5.qtstyleplugin-kvantum gtk-engine-murrine material-icons @@ -157,6 +157,29 @@ in { }; xdg.enable = true; + xresources.properties = with palette-hex; { + "*.foreground" = util.fg; + "*.background" = util.bg; + "*.cursorColor" = util.cursor; + "*.selection_foreground" = util.fg_sel; + "*.selection_background" = util.bg_sel; + "*.color0" = normal.black; + "*.color1" = normal.red; + "*.color2" = normal.green; + "*.color3" = normal.yellow; + "*.color4" = normal.blue; + "*.color5" = normal.magenta; + "*.color6" = normal.cyan; + "*.color7" = normal.white; + "*.color8" = bright.black; + "*.color9" = bright.red; + "*.color10" = bright.green; + "*.color11" = bright.yellow; + "*.color12" = bright.blue; + "*.color13" = bright.magenta; + "*.color14" = bright.cyan; + "*.color15" = bright.white; + }; xdg.configFile = builtins.mapAttrs (name: value: { enable = true; @@ -188,13 +211,6 @@ in { bright.black] (builtins.readFile dots/swaync/style.css)); }; - } // - { - "Kvantum/gruvbox-kvantum" = { - enable = true; - recursive = true; - source = pkgs.rice.kvantum.package; - }; }; xdg.systemDirs.data = [ @@ -294,7 +310,7 @@ in { enable = true; # package = inputs.helix.packages.${pkgs.hostPlatform.system}.default; settings = { - theme = "base16_default"; + theme = "rose_pine"; editor.lsp.display-messages = true; }; }; diff --git a/pkgs/default.nix b/pkgs/default.nix index 03ced2e..302aa9d 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -1,8 +1,10 @@ {pkgs, ...}: { hyprland-system76-scheduler-integration = pkgs.callPackage ./hyprland-system76-scheduler-integration.nix {}; culr = pkgs.callPackage ./culr.nix {}; - gruvbox-kvantum = pkgs.callPackage ./gruvbox-kvantum.nix {}; - gruvbox-gtk-theme = pkgs.callPackage ./gruvbox-gtk-theme.nix {}; + rose-pine-theme = pkgs.callPackage ./rose-pine-theme.nix {}; + rose-pine-icons = pkgs.callPackage ./rose-pine-icons.nix {}; + # gruvbox-kvantum = pkgs.callPackage ./gruvbox-kvantum.nix {}; + # gruvbox-gtk-theme = pkgs.callPackage ./gruvbox-gtk-theme.nix {}; # system76-scheduler = pkgs.callPackage ./system76-scheduler.nix {}; # swayosd = pkgs.callPackage ./swayosd.nix {}; # fuzzel = pkgs.callPackage ./fuzzel.nix {}; diff --git a/pkgs/rose-pine-icons.nix b/pkgs/rose-pine-icons.nix new file mode 100644 index 0000000..d4024c0 --- /dev/null +++ b/pkgs/rose-pine-icons.nix @@ -0,0 +1,35 @@ +{ + stdenv, + fetchFromGitHub, + lib, + gnome-themes-extra, + gtk-engine-murrine, + gtk_engines, +}: +stdenv.mkDerivation rec { + pname = "rose-pine-icons"; + version = "unstable-2023-05-20"; + + src = fetchFromGitHub { + owner = "Fausto-Korpsvart"; + repo = "Rose-Pine-GTK-Theme"; + rev = "95aa1f2b2cc30495b1fc5b614dc555b3eef0e27d"; + sha256 = "sha256-I9UnEhXdJ+HSMFE6R+PRNN3PT6ZAAzqdtdQNQWt7o4Y="; + }; + + buildInputs = [ + gnome-themes-extra # adwaita engine for Gtk2 + gtk_engines # pixmap engine for Gtk2 + ]; + + propagatedUserEnvPkgs = [ + gtk-engine-murrine # murrine engine for Gtk2 + ]; + + installPhase = '' + runHook preInstall + mkdir -p $out/share/icons + cp -a icons/Rose-Pine $out/share/icons/Rose-Pine + runHook postInstall + ''; +} diff --git a/pkgs/rose-pine-theme.nix b/pkgs/rose-pine-theme.nix index 9dcc6cf..fff2b10 100644 --- a/pkgs/rose-pine-theme.nix +++ b/pkgs/rose-pine-theme.nix @@ -7,14 +7,14 @@ gtk_engines, }: stdenv.mkDerivation rec { - pname = "gruvbox-gtk-theme"; + pname = "rose-pine-gtk-theme"; version = "unstable-2023-05-20"; src = fetchFromGitHub { owner = "Fausto-Korpsvart"; - repo = "Gruvbox-GTK-Theme"; - rev = "5927e8693a70619b45fbe3317c59f04f6e101943"; - sha256 = lib.fakeSha256; + repo = "Rose-Pine-GTK-Theme"; + rev = "95aa1f2b2cc30495b1fc5b614dc555b3eef0e27d"; + sha256 = "sha256-I9UnEhXdJ+HSMFE6R+PRNN3PT6ZAAzqdtdQNQWt7o4Y="; }; buildInputs = [ @@ -29,7 +29,7 @@ stdenv.mkDerivation rec { installPhase = '' runHook preInstall mkdir -p $out/share/themes - cp -a themes/Grubvox-Dark-B $out/share/themes + cp -a themes/RosePine-Main-B $out/share/themes/RosePine-Main runHook postInstall ''; } diff --git a/rice.nix b/rice.nix index 9b94d0e..3df2372 100644 --- a/rice.nix +++ b/rice.nix @@ -1,5 +1,5 @@ self: super: let - theme = super.lib.nix-rice.kitty-themes.getThemeByName "GruvboxMaterialDarkMedium"; + theme = super.lib.nix-rice.kitty-themes.getThemeByName "rose-pine"; in rec { rice = { palette = with super.lib.nix-rice; rec { @@ -58,18 +58,18 @@ in rec { }; icons = { - name = "Papirus-Dark"; - package = self.papirus-icon-theme; + name = "oomox-Rose-Pine-Main"; + package = self.rose-pine-icons; }; gtk = { - package = self.gruvbox-gtk-theme; - name = "Gruvbox-Dark"; + package = self.rose-pine-theme; + name = "RosePine-Main"; }; - kvantum = { - package = self.gruvbox-kvantum; - }; + # kvantum = { + # package = self.gruvbox-kvantum; + # }; borders = { thickness = 3; @@ -78,8 +78,8 @@ in rec { bg = { image = super.fetchurl { - sha256 = "sha256-6BCoxgqK5pCxv5P7Rf5MoyLbHAShRd3YuacAcZ916C8="; - url = "https://gruvbox-wallpapers.pages.dev/wallpapers/irl/flowers-2.jpg"; + sha256 = "sha256-8OQCXMy27IImp1Oc/X4i14/8k9XjuuU+6clh0rRcAQY="; + url = "https://github.com/rose-pine/wallpapers/blob/main/rose_pine_contourline.png?raw=true"; }; }; }; # /rice diff --git a/system/configuration.nix b/system/configuration.nix index 121c5ae..8a82e25 100644 --- a/system/configuration.nix +++ b/system/configuration.nix @@ -143,8 +143,8 @@ }; qt.enable = true; - qt.platformTheme = "qt5ct"; - qt.style = "kvantum"; + qt.platformTheme = "gtk2"; + qt.style = "gtk2"; programs.zsh.enable = true; users.defaultUserShell = pkgs.zsh;