lib.mapNixDir: admit just files with .nix suffix
This commit is contained in:
parent
b1d1322e25
commit
eb3285feea
@ -95,9 +95,12 @@ let
|
|||||||
path = dirPath + "/${relPath}";
|
path = dirPath + "/${relPath}";
|
||||||
in
|
in
|
||||||
nameValuePair (toPackageName name) (f path))
|
nameValuePair (toPackageName name) (f path))
|
||||||
(filter
|
(attrNames
|
||||||
(name: name != "default.nix" && !hasPrefix "." name)
|
(filterAttrs
|
||||||
(attrNames (readDir dirPath))));
|
(name: type:
|
||||||
|
(type == "regular" && hasSuffix ".nix" name && name != "default.nix") ||
|
||||||
|
(type == "directory" && !hasPrefix "." name))
|
||||||
|
(readDir dirPath))));
|
||||||
|
|
||||||
# https://tools.ietf.org/html/rfc5952
|
# https://tools.ietf.org/html/rfc5952
|
||||||
normalize-ip6-addr =
|
normalize-ip6-addr =
|
||||||
|
Loading…
Reference in New Issue
Block a user