aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2017-11-24 18:08:50 +0100
committerEelco Dolstra <edolstra@gmail.com>2017-11-24 18:08:50 +0100
commit549c3706a5d63e10d908b43da8479331a844018f (patch)
treea4c36c62672b28b82faf997f8ada7f2c21ede40f /src
parent90948a4e3a64492b7d117d93657221fa7b598e6e (diff)
nix path-info: Show URL of NARs in binary caches
Diffstat (limited to 'src')
-rw-r--r--src/libstore/store-api.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libstore/store-api.cc b/src/libstore/store-api.cc
index 8146513a4..77ab87ef7 100644
--- a/src/libstore/store-api.cc
+++ b/src/libstore/store-api.cc
@@ -516,6 +516,8 @@ void Store::pathInfoToJSON(JSONPlaceholder & jsonOut, const PathSet & storePaths
std::shared_ptr<const ValidPathInfo>(info));
if (narInfo) {
+ if (!narInfo->url.empty())
+ jsonPath.attr("url", narInfo->url);
if (narInfo->fileHash)
jsonPath.attr("downloadHash", narInfo->fileHash.to_string());
if (narInfo->fileSize)