diff options
| author | Jeff Carr <[email protected]> | 2025-10-09 20:28:54 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-10-09 20:28:54 -0500 |
| commit | 71a0b8f19f52dc43e5f4bdfde78eae85fbc7f74e (patch) | |
| tree | ae74169af0134a6b3157b44525d5ad0e1b09b950 /doPatch.go | |
| parent | c3b8d8ae037fc7fa6d63208d430ce9cb28201c6b (diff) | |
more standard function handling
Diffstat (limited to 'doPatch.go')
| -rw-r--r-- | doPatch.go | 21 |
1 files changed, 10 insertions, 11 deletions
@@ -36,7 +36,7 @@ func isPatchingSafe() bool { func doPatch() (string, error) { if argv.Patch.Submit { - return "Submitted", doPatchSubmit() + return doPatchSubmit() } if !isPatchingSafe() { @@ -55,22 +55,20 @@ func doPatch() (string, error) { } // submit's current working patches -func doPatchSubmit() error { +func doPatchSubmit() (string, error) { pset, err := me.forge.MakeDevelPatchSet("testing") if err != nil { - return err + return "MakeDevelPatchSet(testing)", err } if pset.Patches == nil { - log.Info("pset.Patches == nil") - return err + return "pset.Patches == nil", err } if pset.Patches.Len() == 0 { - log.Info("did not find any patches") - return nil + return "did not find any patches", nil } - pset.PrintTable() + footer := pset.PrintTable() _, _, err = pset.HttpPost(myServer(), "new") - return err + return footer, err } func doPatchList() (string, error) { @@ -79,7 +77,8 @@ func doPatchList() (string, error) { if err := curpatches.Load(); err != nil { return "fix curpatches.pb", err } - curpatches.PrintTable() + footer := curpatches.PrintTable() + log.Info("curpatches:", footer) var needfix int for patch := range curpatches.IterAll() { repo := me.forge.Repos.FindByNamespace(patch.Namespace) @@ -115,7 +114,7 @@ func doPatchList() (string, error) { // newNewId, err := searchAllCommits(targetPatchID string) (string, error) { } } - log.Info(patch.PatchId, newId, "new patch", patch.Comment) + log.Info(patch.PatchId, newId, repo.Namespace, "new patch", patch.Comment) if !argv.Fix { needfix += 1 } else { |
