[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
15/16: packages: 'package-field-location' handles missing source propert
From: |
guix-commits |
Subject: |
15/16: packages: 'package-field-location' handles missing source properties. |
Date: |
Sun, 22 Mar 2020 07:43:15 -0400 (EDT) |
civodul pushed a commit to branch master
in repository guix.
commit 91601790d00bbfcdc943b974779cb3d153341ef6
Author: Ludovic Courtès <address@hidden>
AuthorDate: Sun Mar 22 12:31:07 2020 +0100
packages: 'package-field-location' handles missing source properties.
This is a followup to f2b24f01f42c1bad3ddffd140194de1aec38a5f8.
* guix/packages.scm (package-field-location): Check whether
'source-properties->location' returns #f. This fixes the case where
'source-properties' returns the empty list.
---
guix/packages.scm | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/guix/packages.scm b/guix/packages.scm
index 4ab8650..70b1478 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -363,12 +363,12 @@ object."
(let ((field (assoc field inits)))
(match field
((_ value)
- (let ((props (source-properties value)))
- (and props
+ (let ((loc (and=> (source-properties value)
+ source-properties->location)))
+ (and loc
;; Preserve the original file name, which may be a
;; relative file name.
- (let ((loc (source-properties->location props)))
- (set-field loc (location-file) file)))))
+ (set-field loc (location-file) file))))
(_
#f))))
(_
- branch master updated (1550db6 -> 66a198c), guix-commits, 2020/03/22
- 02/16: store: Add 'with-build-handler'., guix-commits, 2020/03/22
- 05/16: deploy: Use 'with-build-handler'., guix-commits, 2020/03/22
- 01/16: syscalls: 'with-file-lock' re-grabs lock when reentering its dynamic extent., guix-commits, 2020/03/22
- 03/16: ui: Add a notification build handler., guix-commits, 2020/03/22
- 04/16: guix build: Use 'with-build-handler'., guix-commits, 2020/03/22
- 08/16: guix system: Use 'with-build-handler'., guix-commits, 2020/03/22
- 10/16: ui: 'show-what-to-build' returns two values, for builds and downloads., guix-commits, 2020/03/22
- 12/16: copy: Factorize 'with-store' & co., guix-commits, 2020/03/22
- 15/16: packages: 'package-field-location' handles missing source properties.,
guix-commits <=
- 13/16: copy: Actually implement '--dry-run'., guix-commits, 2020/03/22
- 07/16: guix package, pull: Use 'with-build-handler'., guix-commits, 2020/03/22
- 06/16: pack: Use 'with-build-handler'., guix-commits, 2020/03/22
- 09/16: ui: 'show-what-to-build' returns true when there are grafts to build., guix-commits, 2020/03/22
- 11/16: ui: 'build-notifier' invokes continuation when there's nothing to do., guix-commits, 2020/03/22
- 14/16: copy: Use 'with-build-handler'., guix-commits, 2020/03/22
- 16/16: hydra: evaluate: Use 'with-build-handler'., guix-commits, 2020/03/22