GNU bug report logs - #55424
[PATCH 000/602] Purge Python 2 packages

Previous Next

Package: guix-patches;

Reported by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Date: Sun, 15 May 2022 04:45:02 UTC

Severity: normal

Tags: patch

Done: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


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

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: 55424 <at> debbugs.gnu.org
Cc: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Subject: [PATCH 005/602] utils: Add a %guix-source-root-directory procedure.
Date: Sun, 15 May 2022 00:36:32 -0400
* guix/utils.scm (%guix-source-root-directory): New procedure.
---
 guix/utils.scm | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/guix/utils.scm b/guix/utils.scm
index e169624ee6..37b2e29800 100644
--- a/guix/utils.scm
+++ b/guix/utils.scm
@@ -78,6 +78,7 @@ (define-module (guix utils)
             substitute-keyword-arguments
             ensure-keyword-arguments
 
+            %guix-source-root-directory
             current-source-directory
 
             nix-system->gnu-triplet
@@ -1031,6 +1032,10 @@ (define (read! bv start n)
 ;;; Source location.
 ;;;
 
+(define (%guix-source-root-directory)
+  "Return the source root directory of the Guix found in %load-path."
+  (dirname (absolute-dirname "guix/packages.scm")))
+
 (define absolute-dirname
   ;; Memoize to avoid repeated 'stat' storms from 'search-path'.
   (mlambda (file)
-- 
2.36.0





This bug report was last modified 3 years and 28 days ago.

Previous Next


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