aboutsummaryrefslogtreecommitdiff
path: root/tests/filter-source.sh
AgeCommit message (Collapse)Author
2020-07-30Add test for builtins.pathMatthew Bauer
2014-08-21Fix testsEelco Dolstra
So all these years I was totally deluded about the meaning of "set -e". You might think that it causes statements like "false && true" or "! true" to fail, but it doesn't...
2011-10-10* Refactoring: remove unnecessary variables from the tests.Eelco Dolstra
2007-01-29New primitives:Eelco Dolstra
* `sub' to subtract two numbers. * `stringLength' to get the length of a string. * `substring' to get a substring of a string. These should be enough to allow most string operations to be expressed.
2007-01-15* builtins.filterSource: pass the type of the file ("regular",Eelco Dolstra
"directory", "symlink") as the second argument to the filter predicate.
2006-12-12* New primop builtins.filterSource, which can be used to filter filesEelco Dolstra
from a source directory. All files for which a predicate function returns true are copied to the store. Typical example is to leave out the .svn directory: stdenv.mkDerivation { ... src = builtins.filterSource (path: baseNameOf (toString path) != ".svn") ./source-dir; # as opposed to # src = ./source-dir; } This is important because the .svn directory influences the hash in a rather unpredictable and variable way.