summaryrefslogtreecommitdiff
path: root/guix/utils.scm
diff options
context:
space:
mode:
authorArun Isaac <arunisaac@systemreboot.net>2022-06-13 16:57:40 +0530
committerArun Isaac <arunisaac@systemreboot.net>2022-06-25 01:43:04 +0530
commit2c05a6112b40c85dd0509052a6a6b97fa127f1c6 (patch)
tree4c0a52244ca7522c98428f14d6e30fae6a278bb4 /guix/utils.scm
parent22aeda1bcc15db33f021c344a95d75984449d72a (diff)
utils: Move switch-symlinks to (guix build utils).
* guix/utils.scm (switch-symlinks): Move to ... * guix/build/utils.scm (switch-symlinks): ... here. * guix/profiles.scm, guix/scripts/home.scm, guix/scripts/package.scm: Import switch-symlinks from (guix build utils). * guix/scripts/system/reconfigure.scm (switch-system-program): Import (guix build utils) in G-expression.
Diffstat (limited to 'guix/utils.scm')
-rw-r--r--guix/utils.scm8
1 files changed, 0 insertions, 8 deletions
diff --git a/guix/utils.scm b/guix/utils.scm
index 5c36b15cfe..e7a576091e 100644
--- a/guix/utils.scm
+++ b/guix/utils.scm
@@ -121,7 +121,6 @@
file-sans-extension
tarball-sans-extension
compressed-file?
- switch-symlinks
call-with-temporary-directory
with-atomic-file-output
@@ -895,13 +894,6 @@ VERSIONS. For example:
(->bool (member (file-extension file)
'("gz" "bz2" "xz" "lz" "lzma" "tgz" "tbz2" "zip"))))
-(define (switch-symlinks link target)
- "Atomically switch LINK, a symbolic link, to point to TARGET. Works
-both when LINK already exists and when it does not."
- (let ((pivot (string-append link ".new")))
- (symlink target pivot)
- (rename-file pivot link)))
-
(define* (string-replace-substring str substr replacement
#:optional
(start 0)