diff options
Diffstat (limited to 'internal/service/git.go')
-rw-r--r-- | internal/service/git.go | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/internal/service/git.go b/internal/service/git.go index b61e332..d56c96b 100644 --- a/internal/service/git.go +++ b/internal/service/git.go @@ -106,6 +106,15 @@ func MirrorGit(dst *internal.URL, src *internal.URL, description string) error { err = mapExecError(err) return fmt.Errorf("cloning: %s", err) } + + // Git mirrors are not good places for mirrored assets. + cmd = exec.Command("git", "config", "set", "cgit.snapshots", "none") + cmd.Dir = dst.Path + err = cmd.Run() + if err != nil { + err = mapExecError(err) + return fmt.Errorf("disabling cgit snapshots: %s", err) + } } err := setDescription(dst.Path, description) |