about summary refs log blame commit diff
path: root/tests/filter-source.nix
blob: 9071636394af387a51b5686fe8664edfaaa339e8 (plain) (tree)
1
2
3
4
5
6
7
8
9
10

                         
                  
                                                          
         


                                                                       
                                                                                  
 
with import ./config.nix;

mkDerivation {
  name = "filter";
  builder = builtins.toFile "builder" "ln -s $input $out";
  input =
    let filter = path: type:
      type != "symlink"
      && baseNameOf path != "foo"
      && !((import ./lang/lib.nix).hasSuffix ".bak" (baseNameOf path));
    in builtins.filterSource filter ((builtins.getEnv "TEST_ROOT") + "/filterin");
}