[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#44344] [PATCH] guix: describe: Improve package provenance tracking.
From: |
Julien Lepiller |
Subject: |
[bug#44344] [PATCH] guix: describe: Improve package provenance tracking. |
Date: |
Sat, 31 Oct 2020 15:40:07 +0100 |
%load-path lists ~/.config/guix/current before individual channels. We
use canonicalize-path to get the store path for channel packages.
* guix/describe.scm (package-provenance): Use canonicalize-path.
---
guix/describe.scm | 28 ++++++++++++++--------------
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/guix/describe.scm b/guix/describe.scm
index 05bf99eb58..fe5921a3b3 100644
--- a/guix/describe.scm
+++ b/guix/describe.scm
@@ -132,25 +132,25 @@ property of manifest entries, or #f if it could not be
determined."
(file
(let ((file (if (string-prefix? "/" file)
file
- (search-path %load-path file))))
+ (canonicalize-path (search-path %load-path file)))))
(and file
(string-prefix? (%store-prefix) file)
;; Always store information about the 'guix' channel and
;; optionally about the specific channel FILE comes from.
- (or (let ((main (and=> (find (lambda (entry)
- (string=? "guix"
- (manifest-entry-name
entry)))
- (current-profile-entries))
- entry-source))
- (extra (any (lambda (entry)
- (let ((item (manifest-entry-item entry)))
- (and (string-prefix? item file)
- (entry-source entry))))
- (current-profile-entries))))
- (and main
- `(,main
- ,@(if extra (list extra) '()))))))))))
+ (let ((main (and=> (find (lambda (entry)
+ (string=? "guix"
+ (manifest-entry-name entry)))
+ (current-profile-entries))
+ entry-source))
+ (extra (any (lambda (entry)
+ (let ((item (manifest-entry-item entry)))
+ (and (string-prefix? item file)
+ (entry-source entry))))
+ (current-profile-entries))))
+ (and main
+ `(,main
+ ,@(if extra (list extra) '())))))))))
(define (manifest-entry-with-provenance entry)
"Return ENTRY with an additional 'provenance' property if it's not already
--
2.28.0
- [bug#44344] [PATCH] guix: describe: Improve package provenance tracking.,
Julien Lepiller <=