1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-13 14:02:42 +01:00

Logger::result(): Support logging arbitrary JSON objects

This commit is contained in:
Eelco Dolstra 2025-03-13 18:23:00 +01:00
parent 220000dc1a
commit 2a2af3f72f
4 changed files with 27 additions and 4 deletions

View file

@ -65,6 +65,12 @@ struct TeeLogger : Logger
logger->result(act, type, fields);
}
void result(ActivityId act, ResultType type, const nlohmann::json & json) override
{
for (auto & logger : loggers)
logger->result(act, type, json);
}
void writeToStdout(std::string_view s) override
{
for (auto & logger : loggers) {