aboutsummaryrefslogtreecommitdiffhomepage
path: root/internal/rosa/git.go
diff options
context:
space:
mode:
authorOphestra <cat@gensokyo.uk>2026-04-04 20:14:40 +0900
committerOphestra <cat@gensokyo.uk>2026-04-04 20:14:40 +0900
commit93ad551054ab17c955454d94b1949cdd8585323c (patch)
tree698050cae16e86444a4a39dc21a43637ef71bad8 /internal/rosa/git.go
parent3d54d1f1767398e8cd17db34047203e090d2a9a9 (diff)
internal/rosa/git: shallow clone
The .git directory is destroyed anyway, so no point fetching more than the bare minimum. Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/rosa/git.go')
-rw-r--r--internal/rosa/git.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/internal/rosa/git.go b/internal/rosa/git.go
index ad3f5b91..e39e0c31 100644
--- a/internal/rosa/git.go
+++ b/internal/rosa/git.go
@@ -105,7 +105,9 @@ func (t Toolchain) NewViaGit(
git \
-c advice.detachedHead=false \
clone \
+ --depth=1 \
--revision=`+rev+` \
+ --shallow-submodules \
--recurse-submodules \
`+url+` \
/work