This commit is contained in:
Louis Dalibard 2024-12-24 16:10:16 +01:00
parent b24763471f
commit 8d1438c222

View File

@ -1,6 +1,9 @@
{ pkgs, inputs, lib, ... }:
let
{
pkgs,
inputs,
lib,
...
}: let
username = "guest";
commonModule = {config, ...}: {
@ -25,10 +28,12 @@ let
};
};
autoload = builtins.concatLists
autoload =
builtins.concatLists
(lib.mapAttrsToList
(name: _:
let testbed = {
(
name: _: let
testbed = {
inherit name;
module = "${inputs.self}/modules/${name}/testbed.nix";
};
@ -37,9 +42,7 @@ let
)
(builtins.readDir "${inputs.self}/modules"));
makeTestbed =
testbed: stylix:
let
makeTestbed = testbed: stylix: let
name = "testbed-${testbed.name}-${stylix.polarity}";
system = lib.nixosSystem {
@ -80,7 +83,8 @@ let
lib.nameValuePair name script;
# This generates a copy of each testbed for each of the following themes.
makeTestbeds = testbed: map (makeTestbed testbed) [
makeTestbeds = testbed:
map (makeTestbed testbed) [
{
enable = true;
image = pkgs.fetchurl {
@ -89,7 +93,7 @@ let
hash = "sha256-S0MumuBGJulUekoGI2oZfUa/50Jw0ZzkqDDu1nRkFUA=";
};
base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-latte.yaml";
polarity = "light";
polarity.force = "light";
}
{
enable = true;
@ -99,9 +103,8 @@ let
hash = "sha256-Dm/0nKiTFOzNtSiARnVg7zM0J1o+EuIdUQ3OAuasM58=";
};
base16Scheme = "${pkgs.base16-schemes}/share/themes/catppuccin-macchiato.yaml";
polarity = "dark";
polarity.force = "dark";
}
];
in
lib.listToAttrs (lib.flatten (map makeTestbeds autoload))