diff options
| author | Jeff Carr <[email protected]> | 2025-02-22 18:55:46 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-02-22 18:55:46 -0600 |
| commit | fd410590876032f703ee3f8bc0dea1ebfb4b7045 (patch) | |
| tree | 168d48a93865fe313836b5b4ea376163e2c7c61b | |
| parent | 642f53dcef6cb54c2351e50c0741574c2f02d853 (diff) | |
keep working on a merge buttonv0.22.96
| -rw-r--r-- | doGui.go | 19 |
1 files changed, 18 insertions, 1 deletions
@@ -234,10 +234,27 @@ func drawWindow(win *gadgets.BasicWindow) { _, box := makeStandardReposWindow("repos to merge from user to devel", found) hbox := box.Box().Horizontal() hbox.NewButton("merge all", func() { + win.Disable() + defer win.Enable() all := found.SortByFullPath() for all.Scan() { repo := all.Next() - log.Info("todo: merge here on", repo.GetGoPath()) + if repo.CheckDirty() { + log.Info("repo is dirty", repo.GetGoPath()) + continue + } + log.Info("Starting merge on", repo.GetGoPath()) + if repo.CheckoutDevel() { + log.Info("checkout devel failed", repo.GetGoPath()) + return + } + if _, err := repo.MergeToDevel(); err != nil { + log.Info("merge from user failed", repo.GetGoPath(), err) + // log.Info(strings.Join(r.Stdout, "\n")) + // log.Info(strings.Join(r.Stderr, "\n")) + return + } + } }) }) |
