feat: integrate nix-citizen and star-citizen support in NixOS configuration
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
{
|
||||
config,
|
||||
inputs,
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
cfg = config.programs.star-citizen;
|
||||
system = pkgs.stdenv.hostPlatform.system;
|
||||
in {
|
||||
options.programs.star-citizen = {
|
||||
enable = lib.mkEnableOption "Star Citizen via nix-citizen";
|
||||
|
||||
package = lib.mkOption {
|
||||
type = lib.types.enum [
|
||||
"rsi-launcher"
|
||||
"rsi-launcher-git"
|
||||
"rsi-launcher-umu"
|
||||
"star-citizen"
|
||||
"star-citizen-git"
|
||||
"star-citizen-umu"
|
||||
"lug-helper"
|
||||
];
|
||||
default = "rsi-launcher";
|
||||
description = "Package from nix-citizen to install when Star Citizen is enabled.";
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
home.packages = [
|
||||
inputs.nix-citizen.packages.${system}.${cfg.package}
|
||||
];
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user