mirror of
https://github.com/NixOS/nix
synced 2025-07-03 06:11:46 +02:00
Add builtins.filterPath
This is like builtins.{filterSource,path}, but returns a virtual path that applies the filter lazily, rather than copying the result to the Nix store. Thus filterPath can be composed.
This commit is contained in:
parent
15d2e0e63b
commit
b48e64162a
6 changed files with 263 additions and 21 deletions
|
@ -525,6 +525,13 @@ public:
|
|||
*/
|
||||
[[nodiscard]] StringMap realiseContext(const PathSet & context);
|
||||
|
||||
/* Call the binary path filter predicate used builtins.path etc. */
|
||||
bool callPathFilter(
|
||||
Value * filterFun,
|
||||
const SourcePath & path,
|
||||
std::string_view pathArg,
|
||||
PosIdx pos);
|
||||
|
||||
private:
|
||||
|
||||
unsigned long nrEnvs = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue