git-pr
created pr with
74.1
cmds
checkout latest patchset:
ssh pr.pico.sh print 74 | git am -3checkout any patchset in a patch request:
ssh pr.pico.sh print 74.[rev] | git am -3add changes to patch request:
git format-patch main --stdout | ssh pr.pico.sh pr add 74
Patchset
74.1
gofumpt and modernize
jolheiser
2025-08-21T18:50:05ZThis is the result of running: - gofumpt -> https://github.com/mvdan/gofumpt - modernize -> https://pkg.go.dev/golang.org/x/tools/gopls/internal/analysis/modernize Signed-off-by: jolheiser <git@jolheiser.com>
Semantic diff summary
0 added,
3 modified,
0 signature changed,
0 removed
across 3 analyzed files
+4
-2
range_diff.go
#
+7
-5
util.go
#
| ... | ... | @@ -15,11 +15,13 @@ import ( | |
| 15 | 15 | "github.com/charmbracelet/ssh" | |
| 16 | 16 | ) | |
| 17 | 17 | ||
| 18 | - | var baseCommitRe = regexp.MustCompile(`base-commit: (.+)\s*`) | |
| 19 | - | var letters = []rune("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ") | |
| 20 | - | var startOfPatch = "From " | |
| 21 | - | var patchsetPrefix = "ps-" | |
| 22 | - | var prPrefix = "pr-" | |
| 18 | + | var ( | |
| 19 | + | baseCommitRe = regexp.MustCompile(`base-commit: (.+)\s*`) | |
| 20 | + | letters = []rune("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ") | |
| 21 | + | startOfPatch = "From " | |
| 22 | + | patchsetPrefix = "ps-" | |
| 23 | + | prPrefix = "pr-" | |
| 24 | + | ) | |
| 23 | 25 | ||
| 24 | 26 | // https://stackoverflow.com/a/22892986 | |
| 25 | 27 | func randSeq(n int) string { |
+1
-7
web.go
#
| ... | ... | @@ -718,13 +718,7 @@ func createPrDetail(page string) http.HandlerFunc { | |
| 718 | 718 | } | |
| 719 | 719 | ||
| 720 | 720 | // highlight review | |
| 721 | - | isReview := false | |
| 722 | - | for _, pID := range reviewIDs { | |
| 723 | - | if pID == patch.ID { | |
| 724 | - | isReview = true | |
| 725 | - | break | |
| 726 | - | } | |
| 727 | - | } | |
| 721 | + | isReview := slices.Contains(reviewIDs, patch.ID) | |
| 728 | 722 | ||
| 729 | 723 | patchFiles := []*PatchFile{} | |
| 730 | 724 | for _, file := range diffFiles { |