Sebastian Walz 860d31cee1
Tohu vaBohu
2023-04-21 00:22:52 +02:00

50 lines
1.3 KiB
Nix

{ configurations, core, nixpkgs, ... }:
let
inherit(configurations) Configuration';
inherit(core) debug list path set string target type;
SystemConfiguration = Configuration' "System";
collect
= hostSystem:
[
(
SystemConfiguration
{
configuration
= { registries, ... }:
{
nixpkgs
= debug.info "collectSystem"
{
text = "registries";
data = set.names registries;
nice = true;
}
{
hostPlatform = string hostSystem;
pkgs = registries.nix;
};
};
inherit(hostSystem) source;
}
)
];
prepare
= environment:
host:
system:
let
system' = target.System system;
in
{
source = host.source "system";
}
// system';
in
{
inherit SystemConfiguration;
inherit collect prepare;
}