2021-02-06 11:31:48 +03:00
|
|
|
{ lib }:
|
|
|
|
let
|
2021-03-14 10:10:51 +03:00
|
|
|
inherit (lib) dev;
|
2021-02-06 11:31:48 +03:00
|
|
|
|
2021-03-14 10:10:51 +03:00
|
|
|
profiles = dev.os.mkProfileAttrs (toString ../profiles);
|
|
|
|
users = dev.os.mkProfileAttrs (toString ../users);
|
2021-02-06 11:31:48 +03:00
|
|
|
|
|
|
|
allProfiles =
|
2021-02-26 00:47:19 +03:00
|
|
|
let defaults = lib.collect (x: x ? default) profiles;
|
|
|
|
in map (x: x.default) defaults;
|
2021-02-06 11:31:48 +03:00
|
|
|
|
2021-02-26 00:47:19 +03:00
|
|
|
allUsers =
|
|
|
|
let defaults = lib.collect (x: x ? default) users;
|
|
|
|
in map (x: x.default) defaults;
|
2021-02-06 11:31:48 +03:00
|
|
|
|
|
|
|
|
|
|
|
suites = with profiles; rec {
|
2021-02-26 00:47:19 +03:00
|
|
|
base = [ users.nixos users.root ];
|
2021-02-06 11:31:48 +03:00
|
|
|
};
|
|
|
|
in
|
2021-03-14 10:10:51 +03:00
|
|
|
lib.mapAttrs (_: v: dev.os.profileMap v) suites // {
|
2021-02-06 11:31:48 +03:00
|
|
|
inherit allProfiles allUsers;
|
|
|
|
}
|