From 4619b7b5750400d4e88a60650e489f0791589148 Mon Sep 17 00:00:00 2001 From: Christopher Baines Date: Thu, 28 Mar 2019 21:02:16 +0000 Subject: [PATCH] Support displaying builtin:download derivations --- guix-data-service/web/view/html.scm | 33 +++++++++++++++++------------ 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/guix-data-service/web/view/html.scm b/guix-data-service/web/view/html.scm index 6d91a92..2be4b22 100644 --- a/guix-data-service/web/view/html.scm +++ b/guix-data-service/web/view/html.scm @@ -519,18 +519,20 @@ (div (@ (class "col-md-4")) (h3 "Inputs") - (table - (@ (class "table")) - (thead - (tr - (th "File name"))) - (tdata - ,@(map (match-lambda - ((file-name output-name path) - `(tr - (td (a (@ (href ,file-name)) - ,(display-store-item-short path)))))) - derivation-inputs)))) + ,(if (null? derivation-inputs) + "No inputs" + `(table + (@ (class "table")) + (thead + (tr + (th "File name"))) + (tdata + ,@(map (match-lambda + ((file-name output-name path) + `(tr + (td (a (@ (href ,file-name)) + ,(display-store-item-short path)))))) + derivation-inputs))))) (div (@ (class "col-md-4")) (h3 "Derivation details") @@ -541,8 +543,11 @@ (tbody (tr (td "Builder") - (td (a (@ (href ,builder)) - ,(display-file-in-store-item builder)))) + (td ,(if (string=? "builtin:download" + builder) + "builtin:download" + `(a (@ (href ,builder)) + ,(display-file-in-store-item builder))))) (tr (td "System") (td (samp ,system)))))))