guix-commits
[Top][All Lists]
Advanced

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

branch master updated: ui: Fix order of match clauses.


From: guix-commits
Subject: branch master updated: ui: Fix order of match clauses.
Date: Thu, 07 Jan 2021 12:12:07 -0500

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

rekado pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new a0f019b  ui: Fix order of match clauses.
a0f019b is described below

commit a0f019b81f9e58bc1290a0d7426cc9558fbed568
Author: Simon Tournier <zimon.toutoune@gmail.com>
AuthorDate: Thu Jan 7 18:08:47 2021 +0100

    ui: Fix order of match clauses.
    
    Fixes <https://bugs.gnu.org/45709>.
    
    This is a follow-up to commit cf289d7cfa34315bf13b3114b9a5bf3d3c05ebea.
    
    * guix/ui.scm (run-guix-command): Match for #false first.
    
    Signed-off-by: Ricardo Wurmus <rekado@elephly.net>
---
 guix/ui.scm | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/guix/ui.scm b/guix/ui.scm
index 7f52518..bd504c6 100644
--- a/guix/ui.scm
+++ b/guix/ui.scm
@@ -13,7 +13,7 @@
 ;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2019 Chris Marusich <cmmarusich@gmail.com>
 ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
-;;; Copyright © 2019 Simon Tournier <zimon.toutoune@gmail.com>
+;;; Copyright © 2019, 2021 Simon Tournier <zimon.toutoune@gmail.com>
 ;;; Copyright © 2020 Arun Isaac <arunisaac@systemreboot.net>
 ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
 ;;;
@@ -2133,11 +2133,11 @@ found."
           (lambda ()
             (match (search-path (extension-directories)
                                 (format #f "~a.scm" command))
+              (#f
+               (throw 'misc-error))
               (file
-               (load file)
-               (resolve-interface `(guix extensions ,command)))
-              (_
-               (throw 'misc-error))))
+                (load file)
+                (resolve-interface `(guix extensions ,command)))))
           (lambda _
             (format (current-error-port)
                     (G_ "guix: ~a: command not found~%") command)



reply via email to

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