[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
14/15: ui: 'show-derivation-outputs' accepts <derivation-input> records.
From: |
guix-commits |
Subject: |
14/15: ui: 'show-derivation-outputs' accepts <derivation-input> records. |
Date: |
Thu, 27 Jun 2019 05:15:47 -0400 (EDT) |
civodul pushed a commit to branch master
in repository guix.
commit 08c95ba28d5d5c9c96f6d1bdcfb75a04e5177a74
Author: Ludovic Courtès <address@hidden>
Date: Sun Jun 23 18:46:53 2019 +0200
ui: 'show-derivation-outputs' accepts <derivation-input> records.
* guix/ui.scm (show-derivation-outputs): Handle <derivation-input>
records.
---
guix/ui.scm | 19 +++++++++++++------
1 file changed, 13 insertions(+), 6 deletions(-)
diff --git a/guix/ui.scm b/guix/ui.scm
index 630afa4..6d243ef 100644
--- a/guix/ui.scm
+++ b/guix/ui.scm
@@ -777,12 +777,19 @@ error."
str))))
(define (show-derivation-outputs derivation)
- "Show the output file names of DERIVATION."
- (format #t "~{~a~%~}"
- (map (match-lambda
- ((out-name . out)
- (derivation->output-path derivation out-name)))
- (derivation-outputs derivation))))
+ "Show the output file names of DERIVATION, which can be a derivation or a
+derivation input."
+ (define (show-outputs derivation outputs)
+ (format #t "~{~a~%~}"
+ (map (cut derivation->output-path derivation <>)
+ outputs)))
+
+ (match derivation
+ ((? derivation?)
+ (show-outputs derivation (derivation-output-names derivation)))
+ ((? derivation-input? input)
+ (show-outputs (derivation-input-derivation input)
+ (derivation-input-sub-derivations input)))))
(define* (check-available-space need
#:optional (directory (%store-prefix)))
- 04/15: ui: Add 'display-search-results' and use it., (continued)
- 04/15: ui: Add 'display-search-results' and use it., guix-commits, 2019/06/27
- 02/15: ui: 'relevance' considers regexps connected with a logical and., guix-commits, 2019/06/27
- 11/15: derivations: 'build-derivations' can be passed derivation inputs., guix-commits, 2019/06/27
- 05/15: derivations: Add 'derivation-input'., guix-commits, 2019/06/27
- 15/15: tests: Avoid TCP port collision between lint.scm and guix-daemon.sh., guix-commits, 2019/06/27
- 13/15: ui: 'show-what-to-build' accepts derivation inputs., guix-commits, 2019/06/27
- 09/15: derivations: <derivation-input> now aggregates a <derivation>., guix-commits, 2019/06/27
- 10/15: derivations: 'derivation' preserves pointer equality., guix-commits, 2019/06/27
- 08/15: graph: Use 'derivation-input-derivation'., guix-commits, 2019/06/27
- 07/15: ui: 'show-what-to-build' uses 'derivation-build-plan'., guix-commits, 2019/06/27
- 14/15: ui: 'show-derivation-outputs' accepts <derivation-input> records.,
guix-commits <=
- 12/15: packages: 'specification->package+output' distinguishes "no output specified"., guix-commits, 2019/06/27