diff --git a/modules/programs/default.nix b/modules/programs/default.nix index 9c30cca..21b91ae 100644 --- a/modules/programs/default.nix +++ b/modules/programs/default.nix @@ -14,6 +14,7 @@ ./firefox.nix ./fish.nix ./git.nix + ./gnome.nix ./gpg.nix ./hub.nix ./kitty.nix diff --git a/modules/programs/gnome.nix b/modules/programs/gnome.nix new file mode 100644 index 0000000..5c9d5a5 --- /dev/null +++ b/modules/programs/gnome.nix @@ -0,0 +1,43 @@ +{ config +, lib +, pkgs +, ... +}: + +with lib; +let + cfg = config.my.programs.gnome; +in +{ + options.my.programs.gnome = { + enable = mkOption { + default = false; + type = types.bool; + example = true; + }; + }; + + config = lib.mkIf cfg.enable { + hardware = { + opengl = { + enable = true; + driSupport = true; + }; + pulseaudio.enable = false; + }; + programs.xwayland.enable = true; + services.xserver = { + layout = "de"; + displayManager = { + autoLogin = { + enable = true; + user = "moritz"; + }; + gdm.enable = true; + }; + enable = true; + desktopManager.gnome.enable = true; + }; + environment.systemPackages = with pkgs.gnomeExtensions; [ pop-shell gsconnect ]; + }; +} diff --git a/modules/services/kdeconnect.nix b/modules/services/kdeconnect.nix index c28121f..6d66419 100644 --- a/modules/services/kdeconnect.nix +++ b/modules/services/kdeconnect.nix @@ -21,8 +21,8 @@ in }; }; - config = lib.mkIf cfg.enable { - home-manager.users.moritz.services.kdeconnect.enable = true; + config = mkIf cfg.enable { + home-manager.users.moritz.services.kdeconnect.enable = mkIf (!config.my.programs.gnome.enable) true; networking.firewall = { allowedTCPPortRanges = [ ports ]; allowedUDPPortRanges = [ ports ];