2024-04-07 22:16:33 -04:00
|
|
|
{
|
|
|
|
pkgs,
|
|
|
|
lib,
|
|
|
|
config,
|
|
|
|
...
|
2024-05-23 23:21:23 -04:00
|
|
|
}: let
|
|
|
|
gnomeCsAdjuster = pkgs.writeShellScriptBin "gnome-cs-adjuster" ''
|
|
|
|
# Get current color scheme
|
|
|
|
color_scheme=$(${lib.getExe' pkgs.glib "gsettings"} get org.gnome.desktop.interface color-scheme)
|
|
|
|
|
|
|
|
# Toggle between light and dark color schemes
|
|
|
|
if [ "$color_scheme" == "'default'" ] || [ "$color_scheme" == "'prefer-light'" ]; then
|
|
|
|
color_scheme="'prefer-dark'"
|
|
|
|
else
|
|
|
|
color_scheme="'prefer-light'"
|
|
|
|
fi
|
|
|
|
|
|
|
|
# Apply the updated color scheme
|
|
|
|
${lib.getExe' pkgs.glib "gsettings"} set org.gnome.desktop.interface color-scheme $color_scheme
|
|
|
|
'';
|
|
|
|
in {
|
2024-04-07 22:16:33 -04:00
|
|
|
imports = [
|
2024-03-28 16:40:23 -04:00
|
|
|
./fprintdFix.nix
|
2024-03-28 16:13:46 -04:00
|
|
|
];
|
|
|
|
|
2024-06-26 22:13:02 -04:00
|
|
|
config = lib.mkIf config.ar.desktop.gnome.enable {
|
2024-05-23 23:21:23 -04:00
|
|
|
environment.systemPackages = with pkgs;
|
|
|
|
[
|
|
|
|
gnomeExtensions.appindicator
|
|
|
|
gnomeExtensions.blur-my-shell
|
|
|
|
gnomeExtensions.gsconnect
|
|
|
|
gnomeExtensions.light-shell
|
|
|
|
gnomeExtensions.night-theme-switcher
|
|
|
|
gnomeExtensions.noannoyance-fork
|
|
|
|
gnomeExtensions.tailscale-status
|
|
|
|
gnomeExtensions.tiling-assistant
|
|
|
|
]
|
|
|
|
++ [gnomeCsAdjuster];
|
2024-03-28 16:13:46 -04:00
|
|
|
|
2024-07-07 14:48:46 -04:00
|
|
|
nixpkgs.overlays = [
|
|
|
|
# GNOME 46: triple-buffering-v4-46
|
|
|
|
(final: prev: {
|
|
|
|
gnome = prev.gnome.overrideScope (gnomeFinal: gnomePrev: {
|
|
|
|
mutter = gnomePrev.mutter.overrideAttrs (old: {
|
|
|
|
src = pkgs.fetchFromGitLab {
|
|
|
|
domain = "gitlab.gnome.org";
|
|
|
|
owner = "vanvugt";
|
|
|
|
repo = "mutter";
|
|
|
|
rev = "triple-buffering-v4-46";
|
|
|
|
hash = "sha256-fkPjB/5DPBX06t7yj0Rb3UEuu5b9mu3aS+jhH18+lpI=";
|
|
|
|
};
|
|
|
|
});
|
|
|
|
});
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2024-03-28 16:13:46 -04:00
|
|
|
# Enable keyring support for KDE apps in GNOME.
|
2024-07-03 10:36:35 -04:00
|
|
|
security.pam.services.gdm = {
|
2024-06-22 15:29:41 -04:00
|
|
|
enableGnomeKeyring = true;
|
|
|
|
gnupg.enable = true;
|
|
|
|
kwallet.enable = true;
|
|
|
|
};
|
2024-03-28 16:13:46 -04:00
|
|
|
|
|
|
|
# Enable GNOME and GDM.
|
|
|
|
services = {
|
|
|
|
gnome.tracker-miners.enable = true;
|
2024-04-07 22:16:33 -04:00
|
|
|
udev.packages = with pkgs; [gnome.gnome-settings-daemon];
|
2024-03-28 16:13:46 -04:00
|
|
|
xserver = {
|
|
|
|
desktopManager.gnome.enable = true;
|
|
|
|
displayManager.gdm.enable = true;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
2024-03-28 16:40:23 -04:00
|
|
|
}
|