]> khamidou — GitHub mirrors - prguy.git/commitdiff
don't show merged PRs 0.8
authorKarim Hamidou <karim@khamidou.com>
Sun, 21 Jul 2024 00:47:28 +0000 (17:47 -0700)
committerKarim Hamidou <karim@khamidou.com>
Sun, 21 Jul 2024 00:47:28 +0000 (17:47 -0700)
cmd/prguy/main.go
cmd/prguy/repos.go

index 667c6ac4b086bd8c453e7ba7fceb23cd64512332..c20c8cb10b92d9ffbcf7a8d98f5593fd8932fffe 100644 (file)
@@ -81,7 +81,7 @@ func setupMenu(ctx context.Context, cancel context.CancelFunc) {
                        systray.ResetMenu()
 
                        if len(myPRs) == 0 {
-                               systray.AddMenuItem("No PRs out from you, let's get after it!", "")
+                               systray.AddMenuItem("No PRs out from you – yet", "")
                        } else {
                                for _, pr := range myPRs {
                                        systrayItem := renderPR(pr)
index 56c05dd0bae68e675509187916aed6db88a6ce23..cb59e50f4cb7ac31e5b93dcadc196d7196873e8b 100644 (file)
@@ -105,6 +105,11 @@ func listUserPRs(token string, isDemo bool) ([]pullRequest, []pullRequest, error
                        }
                }
 
+               merged := prData["merged"].(bool)
+               if merged {
+                       continue
+               }
+
                if prSHA != "" && repoFullName != "" {
                        prStatus, err = getBuildStatus(repoFullName, prSHA, token)
                        if err != nil {