diff --git a/Droidnix/README.org b/Droidnix/README.org index a00cecc1a..753a70cae 100644 --- a/Droidnix/README.org +++ b/Droidnix/README.org @@ -193,6 +193,8 @@ outputs = lib.nixosSystem { inherit system; modules = [ + # Importing Catppuccino mocha + ./generated/out_of_tree/core/theme.nix # Import machine-specific configurations ./generated/out_of_tree/machines/traveldroid/top.nix # Catppuccin theme module @@ -606,6 +608,40 @@ This sets audiosystem for this machine } #+END_SRC +** =generated/out_of_tree/core/theme.nix= +I use the [[https://catppuccin.com/][Catppuccin]] almost everywhere. The nix module integrates almost automatically everywhere (except gtk). +You'll notice the color values in multiple places outside this as well. +#+BEGIN_SRC nix :tangle generated/system/core/theme.nix :noweb tangle :mkdirp yes :eval never-html +{ pkgs, ... }: + +{ + gtk = { + enable = true; + colorScheme = "dark"; + theme = { + name = "Catppuccin-GTK-Grey-Dark-Compact"; + package = (pkgs.magnetic-catppuccin-gtk.override { + accent = [ "grey" ]; + shade = "dark"; + tweaks = [ "black" ]; + size = "compact"; + }); + }; + iconTheme.name = "Papirus-Dark"; + }; + + catppuccin = { + enable = true; + flavor = "mocha"; + accent = "blue"; + gtk = { + icon.enable = true; + }; + cursors.enable = true; + }; +} +#+END_SRC + ** =generated/out_of_tree/machines/traveldroid/xdg.nix= This sets the XDG implementation #+BEGIN_SRC nix :tangle generated/out_of_tree/machines/traveldroid/xdg.nix :noweb tangle :mkdirp yes :eval never-html @@ -616,9 +652,38 @@ This sets the XDG implementation config.system.default = [ "hyprland" "gtk" ]; }; } - #+END_SRC +** =generated/out_of_tree/core/gtk.nix= +I use the [[https://catppuccin.com/][Catppuccin]] almost everywhere. The nix module integrates almost automatically everywhere (except gtk). +You'll notice the color values in multiple places outside this as well. +#+BEGIN_SRC nix :tangle generated/system/out_of_tree/gtk.nix :noweb tangle :mkdirp yes :eval never-html +{ pkgs, user, ... }: +{ + home-manager.users.${user.username} = { + gtk = { + enable = true; + theme = { + name = "Catppuccin-Mocha-Standard-Blue-Dark"; + package = pkgs.magnetic-catppuccin-gtk; + }; + iconTheme = { + name = "Papirus-Dark"; + package = pkgs.papirus-icon-theme; + }; + gtk3.extraConfig = { + gtk-application-prefer-dark-theme = 1; + }; + gtk4.extraConfig = { + gtk-application-prefer-dark-theme = 1; + }; + }; + + }; +} +#+END_SRC + + * Now we reach the top of the hierarchy which will call all other imports ** =generated/top.nix= @@ -1006,7 +1071,6 @@ This is top file of this level which contains just an import statement for all r ./login-tuigreeter.nix #./login-lightdm.nix ./fonts.nix - ./gtk.nix ]; } #+END_SRC @@ -1040,6 +1104,40 @@ You'll notice the color values in multiple places outside this as well. } #+END_SRC +** =generated/system/core/theme.nix= +I use the [[https://catppuccin.com/][Catppuccin]] almost everywhere. The nix module integrates almost automatically everywhere (except gtk). +You'll notice the color values in multiple places outside this as well. +#+BEGIN_SRC nix :tangle generated/system/core/theme.nix :noweb tangle :mkdirp yes :eval never-html +{ pkgs, ... }: + +{ + gtk = { + enable = true; + colorScheme = "dark"; + theme = { + name = "Catppuccin-GTK-Grey-Dark-Compact"; + package = (pkgs.magnetic-catppuccin-gtk.override { + accent = [ "grey" ]; + shade = "dark"; + tweaks = [ "black" ]; + size = "compact"; + }); + }; + iconTheme.name = "Papirus-Dark"; + }; + + catppuccin = { + enable = true; + flavor = "mocha"; + accent = "blue"; + gtk = { + icon.enable = true; + }; + cursors.enable = true; + }; +} +#+END_SRC + ** =generated/system/core/fonts.nix= This file installs and configures fonts diff --git a/Droidnix/flake.nix b/Droidnix/flake.nix index 509632482..c23b0fd48 100644 --- a/Droidnix/flake.nix +++ b/Droidnix/flake.nix @@ -49,6 +49,8 @@ outputs = lib.nixosSystem { inherit system; modules = [ + # Importing Catppuccino mocha + ./generated/out_of_tree/core/theme.nix # Import machine-specific configurations ./generated/out_of_tree/machines/traveldroid/top.nix # Catppuccin theme module diff --git a/Droidnix/generated/system/core/theme.nix b/Droidnix/generated/system/core/theme.nix index a0da544ab..3420ffde3 100644 --- a/Droidnix/generated/system/core/theme.nix +++ b/Droidnix/generated/system/core/theme.nix @@ -1,30 +1,57 @@ -{ pkgs, ...}: -{ - environment.systemPackages = with pkgs; [ - magnetic-catppuccin-gtk - ]; +{ pkgs, ... }: +{ gtk = { enable = true; - theme = { - name = "Catppuccin-Mocha-Standard-Blue-Dark"; - package = pkgs.magnetic-catppuccin-gtk; - }; - iconTheme = { - name = "Papirus-Dark"; - package = pkgs.papirus-icon-theme; - }; - gtk3.extraConfig = { - gtk-application-prefer-dark-theme = 1; - }; - gtk4.extraConfig = { - gtk-application-prefer-dark-theme = 1; + colorScheme = "dark"; + theme = { + name = "Catppuccin-GTK-Grey-Dark-Compact"; + package = (pkgs.magnetic-catppuccin-gtk.override { + accent = [ "grey" ]; + shade = "dark"; + tweaks = [ "black" ]; + size = "compact"; + }); }; + iconTheme.name = "Papirus-Dark"; }; - catppuccin.enable = true; - catppuccin.flavor = "mocha"; - catppuccin.accent = "blue"; - catppuccin.gtk.icon.enable = true; - catppuccin.cursors.enable = true; + catppuccin = { + enable = true; + flavor = "mocha"; + accent = "blue"; + gtk = { + icon.enable = true; + }; + cursors.enable = true; + }; +} + +{ pkgs, ... }: + +{ + gtk = { + enable = true; + colorScheme = "dark"; + theme = { + name = "Catppuccin-GTK-Grey-Dark-Compact"; + package = (pkgs.magnetic-catppuccin-gtk.override { + accent = [ "grey" ]; + shade = "dark"; + tweaks = [ "black" ]; + size = "compact"; + }); + }; + iconTheme.name = "Papirus-Dark"; + }; + + catppuccin = { + enable = true; + flavor = "mocha"; + accent = "blue"; + gtk = { + icon.enable = true; + }; + cursors.enable = true; + }; } diff --git a/Droidnix/generated/system/core/top.nix b/Droidnix/generated/system/core/top.nix index af9461850..a9c1db5a8 100644 --- a/Droidnix/generated/system/core/top.nix +++ b/Droidnix/generated/system/core/top.nix @@ -7,6 +7,5 @@ ./login-tuigreeter.nix #./login-lightdm.nix ./fonts.nix - ./gtk.nix ]; } diff --git a/Droidnix/generated/system/out_of_tree/gtk.nix b/Droidnix/generated/system/out_of_tree/gtk.nix new file mode 100644 index 000000000..50ea31c9e --- /dev/null +++ b/Droidnix/generated/system/out_of_tree/gtk.nix @@ -0,0 +1,23 @@ +{ pkgs, user, ... }: +{ + home-manager.users.${user.username} = { + gtk = { + enable = true; + theme = { + name = "Catppuccin-Mocha-Standard-Blue-Dark"; + package = pkgs.magnetic-catppuccin-gtk; + }; + iconTheme = { + name = "Papirus-Dark"; + package = pkgs.papirus-icon-theme; + }; + gtk3.extraConfig = { + gtk-application-prefer-dark-theme = 1; + }; + gtk4.extraConfig = { + gtk-application-prefer-dark-theme = 1; + }; + }; + + }; +}