readDir
builtins.readDir
Primop
Docs pulled from | This Revision | about 4 hours ago
Takes 1 arguments
path
Return the contents of the directory path as a set mapping
directory entries to the corresponding file type. For instance, if
directory A
contains a regular file B
and another directory
C
, then builtins.readDir ./A
returns the set
{ B = "regular"; C = "directory"; }
The possible values for the file type are "regular"
,
"directory"
, "symlink"
and "unknown"
.
This function is not defined in a .nix file. It is likely a builtins function or an alias of a builtins function. builtins functions are predefined functions provided by Nix.
Noogle detected
Detected Type
readDir :: Path -> AttrSet
Implementation
This function is implemented in c++ and is part of the native nix runtime.