nix-module-wrapper-manager-fds/flake.nix

39 lines
1.2 KiB
Nix
Raw Normal View History

2024-07-02 11:39:25 +00:00
{
description = "wrapper-manager-fds flake";
outputs = { ... }: let
sources = import ./npins;
systems = [ "x86_64-linux" "aarch64-linux" ];
eachSystem = systems: f:
let
# Merge together the outputs for all systems.
op = attrs: system:
let
ret = f system;
op = attrs: key: attrs //
{
${key} = (attrs.${key} or { })
// { ${system} = ret.${key}; };
}
;
in
builtins.foldl' op attrs (builtins.attrNames ret);
in
builtins.foldl' op { }
(systems
++ # add the current system if --impure is used
(if builtins?currentSystem then
if builtins.elem builtins.currentSystem systems
then []
else [ builtins.currentSystem ]
else
[]));
in import ./. { } // (eachSystem systems (system: let
pkgs = import sources.nixos-unstable { inherit system; };
tests = import ./tests { inherit pkgs; };
in {
devShells.default = import ./shell.nix { inherit pkgs; };
checks.wrapperManagerLibrarySetPkg = tests.libTestPkg;
}));
2024-07-02 11:39:25 +00:00
}