nixos/home/hyprland/gtk.nix
Evie Litherland-Smith b0de17462a Attempt to fix gtk theme setting
Add minimal nvim install as backup editor
Add bind to toggle swaync
2023-09-07 14:34:24 +01:00

45 lines
1.3 KiB
Nix

{ config, pkgs, ... }:
let
configure-gtk = pkgs.writeTextFile {
name = "configure-gtk";
destination = "/bin/configure-gtk";
executable = true;
text = let
schema = pkgs.gsettings-desktop-schemas;
datadir = "${schema}/share/gsettings-schemas/${schema.name}";
gtk-theme = config.gtk.theme.name;
icon-theme = config.gtk.iconTheme.name;
cursor-theme = config.gtk.cursorTheme.name;
in ''
export XDG_DATA_DIRS=${datadir}:$XDG_DATA_DIRS
gnome_schema=org.gnome.desktop.interface
gsettings set $gnome_schema gtk-theme '${gtk-theme}'
gsettings set $gnome_schema icon-theme '${icon-theme}'
gsettings set $gnome_schema cursor-theme '${cursor-theme}'
'';
};
catppuccin-gtk-lavender = pkgs.catppuccin-gtk.override {
accents = [ "lavender" ];
size = "standard";
tweaks = [ ];
variant = "mocha";
};
in {
home.packages = [ configure-gtk ];
gtk = {
enable = true;
cursorTheme = {
package = pkgs.catppuccin-cursors.mochaDark;
name = "Catppuccin-Mocha-Dark-Cursors";
};
iconTheme = {
package = pkgs.catppuccin-papirus-folders;
name = "cat-mocha-lavender";
};
theme = {
package = catppuccin-gtk-lavender;
name = "Catppuccin-Mocha-Standard-Lavender";
};
};
}