Compare commits
	
		
			1 commit
		
	
	
		
			286b670b43
			...
			0e83a72c83
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 0e83a72c83 | 
					 4 changed files with 66 additions and 31 deletions
				
			
		|  | @ -5,6 +5,6 @@ | |||
|   ... | ||||
| }: { | ||||
|   imports = [ | ||||
|     ./steam.nix | ||||
|     ./trash | ||||
|   ]; | ||||
| } | ||||
|  |  | |||
|  | @ -1,30 +0,0 @@ | |||
| { | ||||
|   config, | ||||
|   lib, | ||||
|   pkgs, | ||||
|   ... | ||||
| }: | ||||
| with lib; let | ||||
|   cfg = config.local.sys.steam; | ||||
| in { | ||||
|   options.local.sys.steam = { | ||||
|     enable = mkEnableOption "steam settings"; | ||||
|   }; | ||||
|   config = mkIf cfg.enable { | ||||
|     programs.steam = { | ||||
|       enable = true; | ||||
|       remotePlay.openFirewall = true; | ||||
|       dedicatedServer.openFirewall = true; | ||||
|       localNetworkGameTransfers.openFirewall = true; | ||||
|     }; | ||||
| 
 | ||||
|     environment = { | ||||
|       systemPackages = with pkgs; [ | ||||
|         protontricks | ||||
|         protonup | ||||
|         protonup-ng | ||||
|         winetricks | ||||
|       ]; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
							
								
								
									
										10
									
								
								nixos/trash/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								nixos/trash/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,10 @@ | |||
| { | ||||
|   config, | ||||
|   lib, | ||||
|   pkgs, | ||||
|   ... | ||||
| }: { | ||||
|   imports = [ | ||||
|     ./steam | ||||
|   ]; | ||||
| } | ||||
							
								
								
									
										55
									
								
								nixos/trash/steam/default.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										55
									
								
								nixos/trash/steam/default.nix
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,55 @@ | |||
| { | ||||
|   config, | ||||
|   lib, | ||||
|   pkgs, | ||||
|   ... | ||||
| }: | ||||
| with lib; let | ||||
|   cfg = config.options.trivium; | ||||
| in { | ||||
|   options.trivium = { | ||||
|     enable = mkEnableOption "steam settings"; | ||||
| 
 | ||||
|     compatibilityPackages = mkOption { | ||||
|       type = types.bool; | ||||
|       default = true; | ||||
|       description = "Enable additional compatibility packages (protontricks, protonup, etc.)"; | ||||
|     }; | ||||
| 
 | ||||
|     remotePlayOpenFirewall = mkOption { | ||||
|       type = types.bool; | ||||
|       default = false; | ||||
|       description = "Open firewall for Steam Remote Play"; | ||||
|     }; | ||||
| 
 | ||||
|     dedicatedServerOpenFirewall = mkOption { | ||||
|       type = types.bool; | ||||
|       default = false; | ||||
|       description = "Open firewall for Steam Dedicated Server"; | ||||
|     }; | ||||
| 
 | ||||
|     localNetworkGameTransfersOpenFirewall = mkOption { | ||||
|       type = types.bool; | ||||
|       default = false; | ||||
|       description = "Open firewall for Steam Local Network Game Transfers"; | ||||
|     }; | ||||
|   }; | ||||
| 
 | ||||
|   config = mkIf cfg.enable { | ||||
|     programs.steam = { | ||||
|       enable = true; | ||||
|       remotePlay.openFirewall = cfg.remotePlayOpenFirewall; | ||||
|       dedicatedServer.openFirewall = cfg.dedicatedServerOpenFirewall; | ||||
|       localNetworkGameTransfers.openFirewall = cfg.localNetworkGameTransfersOpenFirewall; | ||||
|     }; | ||||
| 
 | ||||
|     environment = mkIf cfg.compatibilityPackages { | ||||
|       systemPackages = with pkgs; [ | ||||
|         protontricks | ||||
|         protonup | ||||
|         protonup-ng | ||||
|         winetricks | ||||
|       ]; | ||||
|     }; | ||||
|   }; | ||||
| } | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue