diff --git a/local/local.go b/local/local.go index bf62bf3..ba29d3c 100644 --- a/local/local.go +++ b/local/local.go @@ -470,6 +470,7 @@ func TempClone(repo types.Repo, tempdir string) (*git.Repository, error) { err = r.Fetch(&git.FetchOptions{ RefSpecs: []config.RefSpec{"refs/*:refs/*"}, Auth: auth, + Force: true, }) if err == git.NoErrAlreadyUpToDate { return r, nil diff --git a/main.go b/main.go index 225d3d5..4fd77a6 100644 --- a/main.go +++ b/main.go @@ -253,6 +253,7 @@ func backup(repos []types.Repo, conf *types.Conf) { log.Error(). Str("stage", "tempclone"). Str("url", r.URL). + Str("git", "clone"). Msg(err.Error()) os.RemoveAll(tempdir) continue @@ -280,6 +281,7 @@ func backup(repos []types.Repo, conf *types.Conf) { log.Error(). Str("stage", "github"). Str("url", r.URL). + Str("git", "push"). Msg(err.Error()) os.RemoveAll(tempdir) continue