GNU bug report logs - #42543
lint failure for packages on load path specified with -L

Previous Next

Package: guix;

Reported by: Jack Hill <jackhill <at> jackhill.us>

Date: Sun, 26 Jul 2020 04:21:01 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #17 received at 42543 <at> debbugs.gnu.org (full text, mbox):

From: zimoun <zimon.toutoune <at> gmail.com>
To: 42543 <at> debbugs.gnu.org
Cc: zimoun <zimon.toutoune <at> gmail.com>
Subject: [PATCH 2/2] scripts: repl: Canonicalize 'load-path' option.
Date: Mon, 27 Jul 2020 23:47:54 +0200
* guix/scripts/repl.scm: Use (guix scripts build) '%standard-build-options' to
deal with 'load-path' option.
---
 guix/scripts/repl.scm | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

diff --git a/guix/scripts/repl.scm b/guix/scripts/repl.scm
index 0ea9c3655c..59edb543d1 100644
--- a/guix/scripts/repl.scm
+++ b/guix/scripts/repl.scm
@@ -21,6 +21,7 @@
 (define-module (guix scripts repl)
   #:use-module (guix ui)
   #:use-module (guix scripts)
+  #:use-module ((guix scripts build) #:select (%standard-build-options))
   #:use-module (guix repl)
   #:use-module (srfi srfi-1)
   #:use-module (srfi srfi-26)
@@ -57,12 +58,9 @@
         (option '(#\q) #f #f
                 (lambda (opt name arg result)
                   (alist-cons 'ignore-dot-guile? #t result)))
-        (option '(#\L "load-path") #t #f
-                (lambda (opt name arg result)
-                  ;; XXX: Imperatively modify the search paths.
-                  (set! %load-path (cons arg %load-path))
-                  (set! %load-compiled-path (cons arg %load-compiled-path))
-                  result))))
+        (find (lambda (option)
+                (member "load-path" (option-names option)))
+              %standard-build-options)))
 
 
 (define (show-help)
-- 
2.26.2





This bug report was last modified 4 years and 267 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.