From 296540a6dbd594a34e6ea3c223081f123ce30c7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= Date: Tue, 5 Mar 2013 22:25:40 +0100 Subject: [PATCH] gnu-maintenance: Fix `gnu-package?' for packages lacking a `source'. * guix/gnu-maintenance.scm (gnu-package?): Support PACKAGE when its source is #f. --- guix/gnu-maintenance.scm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/guix/gnu-maintenance.scm b/guix/gnu-maintenance.scm index 981bb81919..184875300a 100644 --- a/guix/gnu-maintenance.scm +++ b/guix/gnu-maintenance.scm @@ -84,9 +84,10 @@ network to check in GNU's database." ;; TODO: Find a way to determine that a package is non-GNU without going ;; through the network. - (let ((url (origin-uri (package-source package)))) - (or (string-prefix? "mirror://gnu" url) - (member (package-name package) (official-gnu-packages))))))) + (let ((url (and=> (package-source package) origin-uri))) + (or (and (string? url) (string-prefix? "mirror://gnu" url)) + (and (member (package-name package) (official-gnu-packages)) + #t)))))) ;;;