This commit is contained in:
Vegard Bieker Matthey
2026-02-20 18:12:39 +01:00
parent eedb94b998
commit 54a6b687dd
127 changed files with 3804 additions and 2402 deletions

View File

@@ -5,9 +5,12 @@ let
getDir = dir: builtins.readDir dir;
# find all files ending in ".nix" which are not this file, or directories, which may or may not contain a default.nix
files = dir: filterAttrs
(file: type: (type == "regular" && hasSuffix ".nix" file && file != "default.nix") || type == "directory")
(getDir dir);
files =
dir:
filterAttrs (
file: type:
(type == "regular" && hasSuffix ".nix" file && file != "default.nix") || type == "directory"
) (getDir dir);
# Turn the attrset into a list of the filenames
flatten = dir: mapAttrsToList (file: type: file) (files dir);
# Turn the filenames into absolute paths