mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-27 08:16:14 +02:00
Style
This commit is contained in:
parent
2cb7a502a4
commit
f73d911628
1 changed files with 4 additions and 3 deletions
|
@ -1071,18 +1071,19 @@ StorePathSet LocalStore::querySubstitutablePaths(const StorePathSet & paths)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// FIXME: move this, it's not specific to LocalStore.
|
||||||
void LocalStore::querySubstitutablePathInfos(const StorePathCAMap & paths, SubstitutablePathInfos & infos)
|
void LocalStore::querySubstitutablePathInfos(const StorePathCAMap & paths, SubstitutablePathInfos & infos)
|
||||||
{
|
{
|
||||||
if (!settings.useSubstitutes) return;
|
if (!settings.useSubstitutes) return;
|
||||||
for (auto & sub : getDefaultSubstituters()) {
|
for (auto & sub : getDefaultSubstituters()) {
|
||||||
for (auto & path : paths) {
|
for (auto & path : paths) {
|
||||||
if (infos.find(path.first) != infos.end())
|
if (infos.count(path.first))
|
||||||
// choose first succeeding substituter
|
// Choose first succeeding substituter.
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
auto subPath(path.first);
|
auto subPath(path.first);
|
||||||
|
|
||||||
// recompute store path so that we can use a different store root
|
// Recompute store path so that we can use a different store root.
|
||||||
if (path.second) {
|
if (path.second) {
|
||||||
subPath = makeFixedOutputPathFromCA(path.first.name(), *path.second);
|
subPath = makeFixedOutputPathFromCA(path.first.name(), *path.second);
|
||||||
if (sub->storeDir == storeDir)
|
if (sub->storeDir == storeDir)
|
||||||
|
|
Loading…
Reference in a new issue