lib: add isNixDirEntry
This commit is contained in:
parent
eb3285feea
commit
e6863fe8c6
|
@ -96,11 +96,11 @@ let
|
||||||
in
|
in
|
||||||
nameValuePair (toPackageName name) (f path))
|
nameValuePair (toPackageName name) (f path))
|
||||||
(attrNames
|
(attrNames
|
||||||
(filterAttrs
|
(filterAttrs isNixDirEntry (readDir dirPath))));
|
||||||
(name: type:
|
|
||||||
|
isNixDirEntry = name: type:
|
||||||
(type == "regular" && hasSuffix ".nix" name && name != "default.nix") ||
|
(type == "regular" && hasSuffix ".nix" name && name != "default.nix") ||
|
||||||
(type == "directory" && !hasPrefix "." name))
|
(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 a new issue