Disable GNOME's default wallpapers 🍱

Saves 31MiB of disk space.
This commit is contained in:
Daniel Thwaites 2022-11-19 23:02:16 +00:00
parent e634069a2b
commit 921ff2a2bb
No known key found for this signature in database
GPG key ID: D8AFC4BF05670F9D

View file

@ -4,10 +4,10 @@
options.stylix.targets.gnome.enable =
config.lib.stylix.mkEnableTarget "GNOME" true;
config.home-manager.sharedModules =
if config.stylix.polarity == "dark"
then
lib.mkIf config.stylix.targets.gnome.enable [{
config = lib.mkIf config.stylix.targets.gnome.enable {
home-manager.sharedModules =
if config.stylix.polarity == "dark"
then [{
dconf.settings."org/gnome/desktop/background" = {
color-shading-type = "solid";
picture-options = "zoom";
@ -17,12 +17,19 @@
color-scheme = "prefer-dark";
};
}]
else
lib.mkIf config.stylix.targets.gnome.enable [{
else [{
dconf.settings."org/gnome/desktop/background" = {
color-shading-type = "solid";
picture-options = "zoom";
picture-uri = "file://${config.stylix.image}";
};
}];
# As Stylix is controlling the wallpaper, there is no need for this
# pack of default wallpapers to be installed.
# If you want to use one, you can set stylix.image to something like
# "${pkgs.gnome.gnome-backgrounds}/path/to/your/preferred/background"
# which will then download the pack regardless of its exclusion below.
environment.gnome.excludePackages = [ pkgs.gnome.gnome-backgrounds ];
};
}