use pureInputs and filter out nixos-configuration for nix registry

This commit is contained in:
Charlotte 🦝 Delenk 2024-11-11 10:27:54 +01:00
parent 0238865a16
commit 24f25ca3bb

View file

@ -1,12 +1,14 @@
{
lib,
inputs,
pureInputs,
...
}:
let
# Taken from https://github.com/gytis-ivaskevicius/flake-utils-plus/blob/master/lib/options.nix
inherit (lib) filterAttrs mapAttrs';
flakes = filterAttrs (name: value: (value ? outputs)) inputs;
flakes = filterAttrs (
name: value: (value ? outputs) && (name != "self") && (name != "nixos-config")
) pureInputs;
nixRegistry = builtins.mapAttrs (name: v: { flake = v; }) flakes;
in
{