mirror of
https://github.com/NixOS/nix
synced 2025-06-26 20:01:15 +02:00
getBuildLog: factor out resolving derivations
This commit is contained in:
parent
3b27181ee5
commit
e5eb05c599
7 changed files with 16 additions and 19 deletions
|
@ -502,14 +502,9 @@ void BinaryCacheStore::addSignatures(const StorePath & storePath, const StringSe
|
|||
writeNarInfo(narInfo);
|
||||
}
|
||||
|
||||
std::optional<std::string> BinaryCacheStore::getBuildLog(const StorePath & path)
|
||||
std::optional<std::string> BinaryCacheStore::getBuildLogExact(const StorePath & path)
|
||||
{
|
||||
auto maybePath = getBuildDerivationPath(path);
|
||||
if (!maybePath)
|
||||
return std::nullopt;
|
||||
auto drvPath = maybePath.value();
|
||||
|
||||
auto logPath = "log/" + std::string(baseNameOf(printStorePath(drvPath)));
|
||||
auto logPath = "log/" + std::string(baseNameOf(printStorePath(path)));
|
||||
|
||||
debug("fetching build log from binary cache '%s/%s'", getUri(), logPath);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue