guix-commits
[Top][All Lists]
Advanced

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

03/05: scripts: home: Make sure profile directory exists.


From: guix-commits
Subject: 03/05: scripts: home: Make sure profile directory exists.
Date: Sat, 9 Oct 2021 15:23:20 -0400 (EDT)

wigust pushed a commit to branch master
in repository guix.

commit 0f6a27c2c46ab6603a6b1ed9cee99c9f81eca3c5
Author: Oleg Pykhalov <go.wigust@gmail.com>
AuthorDate: Sat Oct 9 14:52:10 2021 +0300

    scripts: home: Make sure profile directory exists.
    
    * guix/scripts/home.scm (process-action): Make sure profile directory 
exists.
---
 gnu/home/services.scm | 3 ++-
 guix/scripts/home.scm | 2 ++
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/gnu/home/services.scm b/gnu/home/services.scm
index c497b14..5c9b743 100644
--- a/gnu/home/services.scm
+++ b/gnu/home/services.scm
@@ -508,7 +508,8 @@ environment, and its configuration file, when available.")))
 
 (define %guix-home-root-directory
   ;; Absolute file name of the module hierarchy.
-  (parent-directory (dirname (search-path %load-path 
"gnu/home/services.scm"))))
+  (parent-directory
+   (dirname (dirname (search-path %load-path "gnu/home/services.scm")))))
 
 (define %service-type-path
   ;; Search path for service types.
diff --git a/guix/scripts/home.scm b/guix/scripts/home.scm
index 8656db2..55e7b43 100644
--- a/guix/scripts/home.scm
+++ b/guix/scripts/home.scm
@@ -2,6 +2,7 @@
 ;;; Copyright © 2021 Andrew Tropin <andrew@trop.in>
 ;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz>
 ;;; Copyright © 2021 Pierre Langlois <pierre.langlois@gmx.com>
+;;; Copyright © 2021 Oleg Pykhalov <go.wigust@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -189,6 +190,7 @@ ACTION must be one of the sub-commands that takes a home 
environment
 declaration as an argument (a file name.)  OPTS is the raw alist of options
 resulting from command-line parsing."
   (define (ensure-home-environment file-or-exp obj)
+    (ensure-profile-directory)
     (unless (home-environment? obj)
       (leave (G_ "'~a' does not return a home environment ~%")
              file-or-exp))



reply via email to

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