guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

branch master updated: upstream: Handle the case where the file name has


From: guix-commits
Subject: branch master updated: upstream: Handle the case where the file name has no extension.
Date: Mon, 27 Jul 2020 07:36:21 -0400

This is an automated email from the git hooks/post-receive script.

dannym pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new bc76f8b  upstream: Handle the case where the file name has no 
extension.
bc76f8b is described below

commit bc76f8b1f9a74c0f187022991b633cc1820944c7
Author: Danny Milosavljevic <dannym@scratchpost.org>
AuthorDate: Mon Jul 27 13:33:39 2020 +0200

    upstream: Handle the case where the file name has no extension.
    
    Fixes <https://bugs.gnu.org/42504>.
    Reported by Alexandru-Sergiu Marton <brown121407@posteo.ro>.
    
    * guix/upstream.scm (package-update/url-fetch): Handle the case where the
    file name has no extension.
---
 guix/upstream.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/guix/upstream.scm b/guix/upstream.scm
index ca18460..6584d5e 100644
--- a/guix/upstream.scm
+++ b/guix/upstream.scm
@@ -369,7 +369,7 @@ SOURCE, an <upstream-source>."
      (let*-values (((archive-type)
                     (match (and=> (package-source package) origin-uri)
                       ((? string? uri)
-                       (let ((type (file-extension (basename uri))))
+                       (let ((type (or (file-extension (basename uri)) "")))
                          ;; Sometimes we have URLs such as
                          ;; "https://github.com/…/tarball/v0.1";, in which case
                          ;; we must not consider "1" as the extension.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]