summaryrefslogtreecommitdiff
path: root/guix
diff options
context:
space:
mode:
authorSimon Tournier <zimon.toutoune@gmail.com>2025-04-15 17:57:00 +0200
committerLudovic Courtès <ludo@gnu.org>2025-06-16 23:11:10 +0200
commit4b68cbbb8d7541eb786e46aa1277e9a396c4c5f4 (patch)
treec1fe68140ebd1ed93465cb2634048a70f7ba5dbd /guix
parent831a3b1263ffb03b0c857d5af1e57eca84b344ed (diff)
git: Move ‘core.autocrlf’ settings.
Follow up of b5e567bb2b277f89af493ba8cd0799fdb368a184. * guix/git.scm (clone*): Move ‘core.autocrlf’ settings from here... (update-cached-checkout): ...to here. Change-Id: I0f91d348376f9953cfbc497148596b738705818b Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'guix')
-rw-r--r--guix/git.scm14
1 files changed, 7 insertions, 7 deletions
diff --git a/guix/git.scm b/guix/git.scm
index c1353c5c04..517e3b8ff0 100644
--- a/guix/git.scm
+++ b/guix/git.scm
@@ -228,12 +228,7 @@ make sure no empty directory is left behind."
(make-clone-options
#:fetch-options (make-default-fetch-options
#:verify-certificate?
- verify-certificate?))))
- (config (repository-config repository)))
- ;; Override 'core.autocrlf' as set in ~/.gitconfig to ensure files are
- ;; left unchanged when cloning and pulling.
- (set-config-string config "core.autocrlf" "input")
-
+ verify-certificate?)))))
repository))
(lambda _
(false-if-exception (rmdir directory)))))
@@ -592,7 +587,12 @@ current settings unchanged."
(repository-open cache-directory)
(clone/swh-fallback url ref cache-directory
#:verify-certificate?
- verify-certificate?))))
+ verify-certificate?)))
+ (config (repository-config repository)))
+ ;; Override 'core.autocrlf' as set in ~/.gitconfig to ensure files are
+ ;; left unchanged when cloning and pulling.
+ (set-config-string config "core.autocrlf" "input")
+
;; Only fetch remote if it has not been cloned just before.
(when (and cache-exists?
(not (reference-available? repository ref)))