1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-25 19:01:16 +02:00

nix verify --all: Support local binary caches

This commit is contained in:
Eelco Dolstra 2016-04-29 17:34:31 +02:00
parent 0dd988d2e3
commit 6963de2091
2 changed files with 16 additions and 2 deletions

View file

@ -33,6 +33,20 @@ protected:
std::shared_ptr<std::string> getFile(const std::string & path) override;
PathSet queryAllValidPaths() override
{
PathSet paths;
for (auto & entry : readDirectory(binaryCacheDir)) {
if (entry.name.size() != 40 ||
!hasSuffix(entry.name, ".narinfo"))
continue;
paths.insert(settings.nixStore + "/" + entry.name.substr(0, entry.name.size() - 8));
}
return paths;
}
};
void LocalBinaryCacheStore::init()