Files
clan-core/flakeModules/clan.nix
a-kenji 16e6b690ad Fix: forward meta attributes in flake-parts module
This fixes building machines with the flake-parts module.

Since the inventory merges the machines, the `clan.core.meta` attribute
is now a submodule and conditionally imported.

Also drops the following attributes:
- clan.core.meta.icon
- clan.core.meta.description

In favor of specifying them inside the inventory.

This doesn't use `mkRemovedOptionsModule`, because in our case it would
cause infinite recursion.
2024-08-07 12:19:17 +00:00

37 lines
667 B
Nix

clan-core:
{
config,
lib,
flake-parts-lib,
self,
inputs,
...
}:
let
inherit (lib) types;
in
{
options.clan = lib.mkOption {
type = types.submoduleWith {
specialArgs = {
inherit clan-core self;
inherit (inputs) nixpkgs;
};
modules = [
../lib/build-clan/interface.nix
../lib/build-clan/module.nix
];
};
};
options.flake = flake-parts-lib.mkSubmoduleOptions {
clanInternals = lib.mkOption { type = types.raw; };
};
config = {
flake.clanInternals = config.clan.clanInternals;
flake.nixosConfigurations = config.clan.nixosConfigurations;
};
_file = __curPos.file;
}