diff --git a/hosts/yodaTab/home-manager.nix b/hosts/yodaTab/home-manager.nix index 47d0359..e39d9c5 100644 --- a/hosts/yodaTab/home-manager.nix +++ b/hosts/yodaTab/home-manager.nix @@ -7,6 +7,7 @@ in imports = [ (import "${home-manager}/nixos") ../../modules/base.home.nix + ../../modules/gnome-config.home.nix ../../modules/gnome-extensions.home.nix ../../modules/git.home.nix ../../modules/zsh.home.nix diff --git a/hosts/yodaTux/home-manager.nix b/hosts/yodaTux/home-manager.nix index 47d0359..0700b8c 100644 --- a/hosts/yodaTux/home-manager.nix +++ b/hosts/yodaTux/home-manager.nix @@ -7,7 +7,9 @@ in imports = [ (import "${home-manager}/nixos") ../../modules/base.home.nix + ../../modules/gnome-config.home.nix ../../modules/gnome-extensions.home.nix + ../../modules/gnome-fractional-scaling.home.nix ../../modules/git.home.nix ../../modules/zsh.home.nix ../../modules/nitrokey-ssh-gpg.home.nix diff --git a/modules/gnome-config.home.nix b/modules/gnome-config.home.nix new file mode 100644 index 0000000..4f7a638 --- /dev/null +++ b/modules/gnome-config.home.nix @@ -0,0 +1,21 @@ +{ config, pkgs, ... }: + +{ + # https://github.com/danieldk/nix-home/blob/master/home/cfg/desktop.nix + + programs.dconf.enable = true; + + home-manager.users.yoda = { osConfig, config, pkgs, ... }: { + dconf.settings = { + "org/gnome/settings-daemon/plugins/color" = { + night-light-enabled = true; + #night-light-temperature = "uint32 3700"; + }; + + "org/gnome/mutter" = { + dynamic-workspaces = true; + workspaces-only-on-primary = true; + }; + }; + }; +} diff --git a/modules/gnome-extensions.home.nix b/modules/gnome-extensions.home.nix index ffdb883..de84cb8 100644 --- a/modules/gnome-extensions.home.nix +++ b/modules/gnome-extensions.home.nix @@ -5,6 +5,8 @@ # https://the-empire.systems/nixos-gnome-settings-and-keyboard-shortcuts # https://hoverbear.org/blog/declarative-gnome-configuration-in-nixos/ + programs.dconf.enable = true; + users.users.yoda = { packages = with pkgs.gnomeExtensions; [ caffeine @@ -12,8 +14,6 @@ ]; }; - programs.dconf.enable = true; - home-manager.users.yoda = { osConfig, config, pkgs, ... }: { # TODO: Alternative # home.packages = with pkgs.gnomeExtensions; [ @@ -30,7 +30,7 @@ pkgs.gnomeExtensions.openweather.extensionUuid ]; # TODO: Alternative to the above - # "org/gnome/shell".enabled-extensions = map (extension: extension.extensionUuid) home.packages; + # enabled-extensions = map (extension: extension.extensionUuid) home.packages; }; # Configure openweather extension. diff --git a/modules/gnome-fractional-scaling.home.nix b/modules/gnome-fractional-scaling.home.nix new file mode 100644 index 0000000..0b27635 --- /dev/null +++ b/modules/gnome-fractional-scaling.home.nix @@ -0,0 +1,16 @@ +{ config, pkgs, ... }: + +{ + # https://wiki.archlinux.org/title/HiDPI#Wayland + # Results in blurry font in non-Wayland applications :/ + + programs.dconf.enable = true; + + home-manager.users.yoda = { osConfig, config, pkgs, ... }: { + dconf.settings = { + "org/gnome/mutter" = { + experimental-features = [ "scale-monitor-framebuffer" ]; + }; + }; + }; +}