diff options
author | Ludovic Courtès <ludo@gnu.org> | 2013-01-09 19:57:44 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2013-01-09 19:57:44 +0100 |
commit | b9e5c0a949fa627da55ea53fd71dfa96ad8a2b4b (patch) | |
tree | 1347ee21801cb69dfe0e97c5a560e2ef268ae42b /guix-package.in | |
parent | 44b6be7744da9cf5513e4e6361681ea277f69097 (diff) | |
download | guix-b9e5c0a949fa627da55ea53fd71dfa96ad8a2b4b.tar.gz |
guix-package: Create ~/.guix-profile when it doesn't exist.
* guix-package.in (guix-package): Create the %USER-ENVIRONMENT-DIRECTORY symlink if it doesn't exist yet. * doc/guix.texi (Invoking guix-package): Document it.
Diffstat (limited to 'guix-package.in')
-rw-r--r-- | guix-package.in | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/guix-package.in b/guix-package.in index 286ae8db09..450d09e081 100644 --- a/guix-package.in +++ b/guix-package.in @@ -458,6 +458,13 @@ Install, remove, or upgrade PACKAGES in a single transaction.\n")) (setvbuf (current-error-port) _IOLBF) (let ((opts (parse-options))) + + ;; Create ~/.guix-profile if it doesn't exist yet. + (when (and %user-environment-directory + %current-profile + (not (file-exists? %user-environment-directory))) + (symlink %current-profile %user-environment-directory)) + (with-error-handling (or (process-query opts) (parameterize ((%guile-for-build @@ -466,7 +473,3 @@ Install, remove, or upgrade PACKAGES in a single transaction.\n")) %bootstrap-guile guile-final)))) (process-actions opts)))))) - -;; Local Variables: -;; eval: (put 'guard 'scheme-indent-function 1) -;; End: |