diff --git a/internal/git/git.go b/internal/git/git.go index a8d966d3..c24cb578 100644 --- a/internal/git/git.go +++ b/internal/git/git.go @@ -383,7 +383,8 @@ func (g *Git) CommitAndPush(openAPIDocVersion, speakeasyVersion, doc string, act } if err := g.repo.Push(&git.PushOptions{ - Auth: getGithubAuth(g.accessToken), + Auth: getGithubAuth(g.accessToken), + Force: true, // This is necessary because at the beginning of the workflow we reset the branch }); err != nil { return "", fmt.Errorf("error pushing changes: %w", err) }