diff --git a/cmd/pkgdashcli/main.go b/cmd/pkgdashcli/main.go index 271ce71..9fb9547 100644 --- a/cmd/pkgdashcli/main.go +++ b/cmd/pkgdashcli/main.go @@ -225,7 +225,7 @@ func giteaPullRequest(ctx context.Context, cfg *Config, mods map[string]modules. wTitle.Reset() wBody.Reset() - fmt.Printf("update %s from %s to %s\n", path, mod.Module.Version, mod.Version) + logger.Infof(ctx, "update %s from %s to %s\n", path, mod.Module.Version, mod.Version) newref := plumbing.NewHashReference(plumbing.ReferenceName(fmt.Sprintf("refs/heads/pkgdash/go_modules/%s-%s", path, mod.Version)), headRef.Hash()) if err = repo.Storer.SetReference(newref); err != nil { @@ -267,13 +267,17 @@ func giteaPullRequest(ctx context.Context, cfg *Config, mods map[string]modules. logger.Fatalf(ctx, "failed to run go mod tidy: %s err: %v", out, err) } + logger.Infof(ctx, "worktree add go.mod") if _, err = wtree.Add("go.mod"); err != nil { logger.Fatalf(ctx, "failed to add file: %v", err) } + + logger.Infof(ctx, "worktree add go.sum") if _, err = wtree.Add("go.sum"); err != nil { logger.Fatalf(ctx, "failed to add file: %v", err) } + logger.Infof(ctx, "worktree commit") _, err = wtree.Commit(wTitle.String(), &git.CommitOptions{ Author: &object.Signature{ Name: "gitea-actions ",