* builtins.filterSource: pass the type of the file ("regular",
"directory", "symlink") as the second argument to the filter predicate.
This commit is contained in:
parent
63f3ce6d9a
commit
e4b0666f8e
3 changed files with 23 additions and 2 deletions
|
@ -3,5 +3,7 @@ derivation {
|
|||
system = "@system@";
|
||||
builder = "@shell@";
|
||||
args = ["-e" "-x" (builtins.toFile "builder" "PATH=@testPath@; ln -s $input $out")];
|
||||
input = builtins.filterSource (path: baseNameOf (toString path) != "foo") ./test-tmp/filterin;
|
||||
input =
|
||||
let filter = path: type: type != "symlink" && baseNameOf (toString path) != "foo";
|
||||
in builtins.filterSource filter ./test-tmp/filterin;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue