mirror of
https://github.com/CHN-beta/nixos.git
synced 2024-10-23 09:08:45 +08:00
整理一些packages
This commit is contained in:
parent
9e52369fd0
commit
11e6287c26
@ -143,6 +143,7 @@
|
||||
./modules/fileSystems
|
||||
./modules/kernel
|
||||
./modules/hardware
|
||||
./modules/packages
|
||||
(inputs: { config.nixos =
|
||||
{
|
||||
fileSystems =
|
||||
@ -177,6 +178,10 @@
|
||||
bluetooth.enable = true;
|
||||
joystick.enable = true;
|
||||
};
|
||||
packages =
|
||||
{
|
||||
packages = [ "genshin-impact" "honkers-star-rail" ];
|
||||
};
|
||||
};}
|
||||
)
|
||||
|
||||
|
25
modules/packages/default.nix
Normal file
25
modules/packages/default.nix
Normal file
@ -0,0 +1,25 @@
|
||||
inputs:
|
||||
{
|
||||
options.nixos.packages = let inherit (inputs.lib) mkOption types; in
|
||||
{
|
||||
packages = mkOption { default = []; type = types.listOf (types.enum
|
||||
[
|
||||
# games
|
||||
"genshin-impact" "honkers-star-rail"
|
||||
]); };
|
||||
};
|
||||
config =
|
||||
{
|
||||
programs = {}
|
||||
// (
|
||||
if builtins.elem "genshin-impact" inputs.config.nixos.packages.packages
|
||||
then { anime-game-launcher.enable = true; }
|
||||
else {}
|
||||
)
|
||||
// (
|
||||
if builtins.elem "honkers-star-rail" inputs.config.nixos.packages.packages
|
||||
then { honkers-railway-launcher.enable = true; }
|
||||
else {}
|
||||
);
|
||||
};
|
||||
}
|
@ -3,11 +3,6 @@ inputs:
|
||||
config =
|
||||
{
|
||||
environment.systemPackages = [ inputs.config.nur.repos.ataraxiasjel.proton-ge inputs.pkgs.wine ];
|
||||
programs =
|
||||
{
|
||||
anime-game-launcher.enable = true;
|
||||
honkers-railway-launcher.enable = true;
|
||||
steam.enable = true;
|
||||
};
|
||||
programs.steam.enable = true;
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user