gitignoreSource: ensure Nix store path determinism

This ensures that, when used in situations like `gitignoreSource ./.`,                                          
both Hydra and local checkout will have the exact same Nix path.
This commit is contained in:
Yegor Timoshenko 2019-08-19 16:16:12 +00:00 committed by GitHub
parent ec5dd0536a
commit f7c8b7f8d1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,5 +4,10 @@ let
in
{
inherit (find-files) gitignoreFilter;
gitignoreSource = p: lib.cleanSourceWith { filter = find-files.gitignoreFilter p; src = p; };
gitignoreSource = path: builtins.path {
name = "source";
filter = find-files.gitignoreFilter path;
inherit path;
};
}