vole
Clone
Read only, no credentials:
https://rodent.software/git/vole.git
Write over SSH with a registered key:
git clone ssh://git@0.0.0.0:2222/vole.git
A free and open-source forge that lives in your Git repo.
Give merged change requests their own colour and filter
0e35a6a00a03201f382c9669d01c2af81f3dbdd5 · Keenan Nemetz · 11d ago · parent f2360c20
Give merged change requests their own colour and filter The merged state borrowed --accent, which is green in Everforest and therefore read like an open request. It now has its own purple tokens in both the fallback and Everforest themes. The list also gains a Merged chip with its own count. Closed now counts only requests that were closed without landing, so the three state filters partition the list instead of overlapping.
server/web/requests.go +8−4
| @@ -104,7 +104,7 @@ func (w *Web) Requests(rw http.ResponseWriter, r *http.Request) { | |||
| 104 | 104 | if state == "" { | |
| 105 | 105 | state = "open" | |
| 106 | 106 | } | |
| 107 | if state != "open" && state != "closed" && state != "all" { | ||
| 107 | if state != "open" && state != "merged" && state != "closed" && state != "all" { | ||
| 108 | 108 | state = "open" | |
| 109 | 109 | } | |
| 110 | 110 | query := strings.TrimSpace(r.URL.Query().Get("q")) | |
| @@ -112,10 +112,13 @@ func (w *Web) Requests(rw http.ResponseWriter, r *http.Request) { | |||
| 112 | 112 | nums := w.entityNumbers(m) | |
| 113 | 113 | acl, _ := m.ACL() | |
| 114 | 114 | rows := make([]requestRow, 0, len(list)) | |
| 115 | open := 0 | ||
| 115 | open, merged := 0, 0 | ||
| 116 | 116 | for _, req := range list { | |
| 117 | if req.State == "open" { | ||
| 117 | switch req.State { | ||
| 118 | case "open": | ||
| 118 | 119 | open++ | |
| 120 | case "merged": | ||
| 121 | merged++ | ||
| 119 | 122 | } | |
| 120 | 123 | if state != "all" && req.State != state { | |
| 121 | 124 | continue | |
| @@ -155,6 +158,7 @@ func (w *Web) Requests(rw http.ResponseWriter, r *http.Request) { | |||
| 155 | 158 | State string | |
| 156 | 159 | Query string | |
| 157 | 160 | Open int | |
| 161 | Merged int | ||
| 158 | 162 | Total int | |
| 159 | 163 | Closed int | |
| 160 | 164 | Required int | |
| @@ -167,7 +171,7 @@ func (w *Web) Requests(rw http.ResponseWriter, r *http.Request) { | |||
| 167 | 171 | }{ | |
| 168 | 172 | Page: w.page(r, m.Name+" · change requests"), Name: m.Name, Rows: rows, State: state, | |
| 169 | 173 | Numbers: nums, | |
| 170 | Query: query, Open: open, Total: len(list), Closed: len(list) - open, | ||
| 174 | Query: query, Open: open, Merged: merged, Total: len(list), Closed: len(list) - open - merged, | ||
| 171 | 175 | Required: required, Filtered: query != "" || (state != "open" && len(list) > 0), | |
| 172 | 176 | CanOpen: form.CanOpen, Base: form.Base, | |
| 173 | 177 | BaseBranches: form.BaseBranches, HeadBranches: form.HeadBranches, | |