summaryrefslogtreecommitdiff
path: root/release.nix
blob: 6e676e02bffc42998d9a30e2bea369cf81eaddca (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#──────────────────────────────────────────────────────────────────────────────┐
# SPDX-FileCopyrightText: 2025 toastal <https://toast.al/contact/>             │
# SPDX-License-Identifier: LGPL-2.1-or-later                                   │
#──────────────────────────────────────────────────────────────────────────────┘
let
   inputs = import ./nix/tamal { };

   pkgs = import inputs.nixpkgs {
      overlays = [
         (import ./nix/overlay/default.nix)
         (import ./nix/overlay/development.nix)
         (import ./nix/overlay/check.nix)
      ];
   };

   inherit (pkgs) lib;
in
{
   inherit (pkgs) nixtamal;

   inherit (pkgs.nixtamal) default;

   shell = pkgs.nixtamal.dev-shell;

   check = lib.concatMapAttrs (
      parent: children:
      if lib.isDerivation children then
         { ${parent} = children; }
      else
         lib.mapAttrs' (child: value: {
            name = "${parent}_${child}";
            inherit value;
         }) children
   ) pkgs.nixtamal.check;
}