move gtk theme to firefox

This commit is contained in:
Noah Masur 2022-04-28 23:04:48 -04:00
parent 4735cce26f
commit 4da5e381b2
3 changed files with 12 additions and 13 deletions

View File

@ -28,6 +28,7 @@
name = "Victor Mono"; name = "Victor Mono";
}; };
hostname = "nixos"; hostname = "nixos";
gtkTheme = "Adwaita-dark";
in { in {
nixosConfigurations = { nixosConfigurations = {
@ -35,7 +36,7 @@
inherit system; inherit system;
specialArgs = { specialArgs = {
gui = true; gui = true;
inherit user fullName font hostname; inherit user fullName font hostname gtkTheme;
}; };
modules = [ modules = [
home-manager.nixosModules.home-manager home-manager.nixosModules.home-manager

View File

@ -1,12 +1,19 @@
{ pkgs, lib, user, gui, ... }: { pkgs, lib, user, gui, gtkTheme, ... }:
{ {
config = lib.mkIf gui { config = lib.mkIf gui {
home-manager.users.${user}.home.packages = [ pkgs.firefox ]; home-manager.users.${user} = {
home.packages = [ pkgs.firefox ];
gtk = {
enable = true;
theme = { name = gtkTheme; };
};
};
# Required for setting GTK theme (for preferred-color-scheme in browser) # Required for setting GTK theme (for preferred-color-scheme in browser)
services.dbus.packages = [ pkgs.dconf ]; services.dbus.packages = [ pkgs.dconf ];
programs.dconf.enable = true; programs.dconf.enable = true;
}; };
} }

View File

@ -1,8 +1,4 @@
{ pkgs, user, gui, ... }: { pkgs, user, gui, gtkTheme, ... }: {
let gtkTheme = "Adwaita-dark";
in {
# Enable the X11 windowing system. # Enable the X11 windowing system.
services.xserver = { services.xserver = {
@ -29,10 +25,5 @@ in {
xclip # Clipboard xclip # Clipboard
]; ];
home-manager.users.${user}.gtk = {
enable = true;
theme = { name = gtkTheme; };
};
} }