diff --git a/modules/default.nix b/modules/default.nix index 98e07d3..97da4da 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -1,8 +1,15 @@ { lib, pkgs, ... }: { - imports = - [ ./cachix.nix ./cli ./desktop ./editors ./services ./security.nix ]; + imports = [ + ./cachix.nix + ./cli + ./desktop + ./editors + ./gaming.nix + ./security.nix + ./services + ]; # USERS users.users.moritz = { diff --git a/modules/gaming.nix b/modules/gaming.nix new file mode 100644 index 0000000..40f91c4 --- /dev/null +++ b/modules/gaming.nix @@ -0,0 +1,19 @@ +{ config, lib, pkgs, ... }: + +with lib; +let cfg = config.modules.gaming; +in { + options.modules.gaming = mkOption { + default = false; + type = types.bool; + example = true; + }; + + config = mkIf cfg { + programs.steam.enable = true; + home-manager.users.moritz.home.packages = with pkgs; [ + lutris + legendary-gl + ]; + }; +} diff --git a/modules/gaming/default.nix b/modules/gaming/default.nix deleted file mode 100644 index 55e0a41..0000000 --- a/modules/gaming/default.nix +++ /dev/null @@ -1,6 +0,0 @@ -{ config, lib, pkgs, ... }: - -{ - programs.steam.enable = true; - home-manager.users.moritz.home.packages = with pkgs; [ lutris legendary-gl ]; -}