diff --git a/machines/boxy/configuration.nix b/machines/boxy/configuration.nix index 556e3fc..a02fdf9 100644 --- a/machines/boxy/configuration.nix +++ b/machines/boxy/configuration.nix @@ -17,7 +17,7 @@ with lib; bluetooth.enable = true; desktop = { enable = true; - gaming = true; + gaming.enable = true; kde = true; sddm = true; wayland = true; diff --git a/machines/nix-book/configuration.nix b/machines/nix-book/configuration.nix index f6c0fe9..8784c18 100644 --- a/machines/nix-book/configuration.nix +++ b/machines/nix-book/configuration.nix @@ -15,7 +15,7 @@ desktop = { enable = true; wayland = true; - gaming = false; + gaming.enable = false; kde = true; sddm = true; }; diff --git a/machines/zix790prors/configuration.nix b/machines/zix790prors/configuration.nix index 3bf807e..f4b55ee 100644 --- a/machines/zix790prors/configuration.nix +++ b/machines/zix790prors/configuration.nix @@ -17,11 +17,15 @@ with lib; bluetooth.enable = true; desktop = { enable = true; - gaming = true; + gaming = { + enable = true; + emulation = true; + }; kde = true; sddm = true; wayland = true; }; + nfs-mounts.enable = true; users.enable = true; virtualisation.enable = true; }; @@ -82,4 +86,4 @@ with lib; # For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion . system.stateVersion = "25.11"; # Did you read the comment? -} \ No newline at end of file +} diff --git a/roles/desktop/default.nix b/roles/desktop/default.nix index 60668a9..3c206ff 100644 --- a/roles/desktop/default.nix +++ b/roles/desktop/default.nix @@ -9,7 +9,10 @@ with lib; x11 = mkOption { type = types.bool; default = false; description = "Enable X11 support."; }; wayland = mkOption { type = types.bool; default = false; description = "Enable Wayland support."; }; kde = mkOption { type = types.bool; default = false; description = "Enable KDE."; }; - gaming = mkOption { type = types.bool; default = false; description = "Enable gaming support."; }; + gaming = { + enable = mkOption { type = types.bool; default = false; description = "Enable gaming support."; }; + emulation = mkOption { type = types.bool; default = false; description = "Enable emulation support."; }; + }; sddm = mkOption { type = types.bool; default = false; description = "Enable SDDM greeter."; }; }; diff --git a/roles/desktop/gaming.nix b/roles/desktop/gaming.nix index 48bc55c..6a3b760 100644 --- a/roles/desktop/gaming.nix +++ b/roles/desktop/gaming.nix @@ -6,13 +6,22 @@ let cfg = config.roles.desktop; in { - config = mkIf (cfg.enable && cfg.gaming) { - environment.systemPackages = with pkgs; [ - steam - lutris - moonlight - ]; + config = mkMerge [ + (mkIf (cfg.enable && cfg.gaming.enable) { + environment.systemPackages = with pkgs; [ + steam + lutris + moonlight + ]; - # Possibly other gaming specific services or settings - }; + # Possibly other gaming specific services or settings + }) + + (mkIf (cfg.enable && cfg.gaming.emulation) { + environment.systemPackages = with pkgs; [ + ryujinx + dolphin-emu + ]; + }) + ]; }