Added machineIcon and machineDescription to buildClan

This commit is contained in:
Qubasa
2024-02-05 14:18:40 +07:00
parent fc50d8748a
commit b3815527a5
5 changed files with 25 additions and 4 deletions

View File

@@ -3,7 +3,9 @@
, specialArgs ? { } # Extra arguments to pass to nixosSystem i.e. useful to make self available
, machines ? { } # allows to include machine-specific modules i.e. machines.${name} = { ... }
, clanName # Needs to be (globally) unique, as this determines the folder name where the flake gets downloaded to.
, clanIcon ? null # A path to an icon to be used for the clan
, clanIcon ? null # A path to an icon to be used for the clan, should be the same for all machines
, machineIcon ? null # A path to an icon to be used for the machine
, machineDescription ? null # A description of the machine
}:
let
machinesDirs = lib.optionalAttrs (builtins.pathExists "${directory}/machines") (builtins.readDir (directory + /machines));
@@ -45,6 +47,8 @@ let
clanCore.clanName = clanName;
clanCore.clanIcon = clanIcon;
clanCore.clanDir = directory;
clanCore.machineIcon = machineIcon;
clanCore.machineDescription = machineDescription;
nixpkgs.hostPlatform = if forceSystem then lib.mkForce system else lib.mkDefault system;
# speeds up nix commands by using the nixpkgs from the host system (especially useful in VMs)