Commit 078b91ce3e
Verified · cmc ci/build: success ci/test: success
e2e/dashboard_test.go +1 −1
| @@ -97,7 +97,7 @@ func TestDashboard(t *testing.T) { | ||
| 97 | 97 | "Waiting on your review", "assigned to you", "Recent activity", |
| 98 | 98 | "from bob", "alice/app!1", "todo one", "alice/app#1", |
| 99 | 99 | `href="/alice/app/mrs/1"`, `href="/alice/app/issues/1"`, |
| 100 | "Yours anywhere, and every one in a repository you can write to.", | |
| 100 | "Your MRs across all repos.", | |
| 101 | 101 | } { |
| 102 | 102 | if !strings.Contains(body, want) { |
| 103 | 103 | t.Errorf("dashboard missing %q", want) |
internal/web/templates/404.html +1 −1
| @@ -4,7 +4,7 @@ | ||
| 4 | 4 | <div class="notfound"> |
| 5 | 5 | <p class="bigcode">404</p> |
| 6 | 6 | <h1>Page not found</h1> |
| 7 | <p class="desc">nothing lives at this address — the path may be wrong, | |
| 7 | <p class="desc">nothing lives at this address. the path may be wrong, | |
| 8 | 8 | or the repository may be private.</p> |
| 9 | 9 | <p><a href="/">← back to {{.Site}}</a></p> |
| 10 | 10 | </div> |
internal/web/templates/account.html +8 −9
| @@ -48,8 +48,7 @@ Write it with a push, or edit it here.</p> | ||
| 48 | 48 | |
| 49 | 49 | <section id="keys"><h2>SSH keys</h2> |
| 50 | 50 | <p class="meta">Your keys are your identity here. A <code>full</code> key can run |
| 51 | commands and push; a <code>git</code> key can only move git data, which is what | |
| 52 | a CI checkout wants.</p> | |
| 51 | commands and push; a <code>git</code> key can only move git data (e.g., CI).</p> | |
| 53 | 52 | {{if .Keys}}<div class="tablewrap"><table class="keys nowrap"> |
| 54 | 53 | <tr class="cols"><th scope="col">label</th><th scope="col">fingerprint</th><th scope="col">type</th><th scope="col">scope</th><th scope="col"><span class="vh">actions</span></th></tr> |
| 55 | 54 | {{range .Keys}}<tr> |
| @@ -60,7 +59,7 @@ a CI checkout wants.</p> | ||
| 60 | 59 | <td class="act"><form method="post" action="/settings"><input type="hidden" name="field" value="key-remove"><input type="hidden" name="fingerprint" value="{{.Fingerprint}}">{{template "confirmfield" .Confirm}} <button type="submit" class="danger">Remove</button></form></td> |
| 61 | 60 | </tr> |
| 62 | 61 | {{end}}</table></div> |
| 63 | {{else}}<p class="none">No SSH keys — which cannot be right, since you signed in.</p>{{end}} | |
| 62 | {{else}}<p class="none">No SSH keys? Which cannot be right, since you signed in.</p>{{end}} | |
| 64 | 63 | <details class="editbox"> |
| 65 | 64 | <summary>Add an SSH key</summary> |
| 66 | 65 | <form method="post" action="/settings" class="setform stack"> |
| @@ -71,8 +70,8 @@ a CI checkout wants.</p> | ||
| 71 | 70 | <input id="key-label" name="label" maxlength="64" placeholder="defaults to the key's comment"> |
| 72 | 71 | <label for="scope">Scope</label> |
| 73 | 72 | <select id="scope" name="scope"> |
| 74 | <option value="full">full — commands and git</option> | |
| 75 | <option value="git">git — git transport only</option> | |
| 73 | <option value="full">full: commands and git</option> | |
| 74 | <option value="git">git: git transport only</option> | |
| 76 | 75 | </select> |
| 77 | 76 | <button type="submit" class="btn">Add key</button> |
| 78 | 77 | </form> |
| @@ -80,8 +79,8 @@ a CI checkout wants.</p> | ||
| 80 | 79 | </section> |
| 81 | 80 | |
| 82 | 81 | <section id="emails"><h2>Email addresses</h2> |
| 83 | <p class="meta">A verified address is what ties your signed commits to this | |
| 84 | account, and where notifications go.</p> | |
| 82 | <p class="meta">A verified address ties signed commits to this | |
| 83 | account and where notifications go.</p> | |
| 85 | 84 | {{if .Emails}}<ul class="plain"> |
| 86 | 85 | {{range .Emails}}<li>{{.Address}} |
| 87 | 86 | {{if .Primary}}<span class="chip">primary</span>{{end}} |
| @@ -137,14 +136,14 @@ account, and where notifications go.</p> | ||
| 137 | 136 | <input type="checkbox" id="notify-mail" name="mail" value="on"{{if .MailOn}} checked{{end}}> |
| 138 | 137 | <button type="submit" class="btn">Save</button> |
| 139 | 138 | </form> |
| 140 | <p class="meta">The inbox is filed either way; this is the mail half. Login links are not activity and still arrive.</p> | |
| 139 | <p class="meta">Enable to receive activity alerts by email. Login links will arrive regardless of this setting.</p> | |
| 141 | 140 | <form method="post" action="/settings" class="setform"> |
| 142 | 141 | <input type="hidden" name="field" value="notify-watch"> |
| 143 | 142 | <label for="notify-watch">Watch repositories you can write to</label> |
| 144 | 143 | <input type="checkbox" id="notify-watch" name="watch" value="on"{{if .WatchOn}} checked{{end}}> |
| 145 | 144 | <button type="submit" class="btn">Save</button> |
| 146 | 145 | </form> |
| 147 | <p class="meta">Every issue and merge request on those repositories, as if you had watched each. A watch or mute on a repository still wins.</p> | |
| 146 | <p class="meta">Alerts for every issue and merge request on those repositories. A watch or mute on a repository has priority over this setting.</p> | |
| 148 | 147 | </section> |
| 149 | 148 | |
| 150 | 149 | <section id="appearance"><h2>Appearance</h2> |
internal/web/templates/admin.html +2 −2
| @@ -2,8 +2,8 @@ | ||
| 2 | 2 | {{define "title"}}admin · {{.Site}}{{end}} |
| 3 | 3 | {{define "content"}} |
| 4 | 4 | <h1>Admin</h1> |
| 5 | <p class="meta">Server build {{.Commit}}. Every background worker's backlog, the same read as <code>gitbay dashboard --json</code> for an admin.</p> | |
| 6 | <p class="meta"><a href="/admin/users">Accounts</a> — every account, with promote, demote, disable and enable.</p> | |
| 5 | <p class="meta">Server build {{.Commit}}. Every background worker's backlog. This is the same read as <code>gitbay dashboard --json</code> for an admin.</p> | |
| 6 | <p class="meta"><a href="/admin/users">Accounts</a>: view every instance user account.</p> | |
| 7 | 7 | |
| 8 | 8 | <div class="withcol narrow"> |
| 9 | 9 | <nav class="sidecol" aria-label="Sections"> |
internal/web/templates/bookmarks.html +3 −3
| @@ -2,8 +2,8 @@ | ||
| 2 | 2 | {{define "content"}} |
| 3 | 3 | <h1>Bookmarks</h1> |
| 4 | 4 | <p class="meta">Repositories you saved to come back to. A pin is private quick |
| 5 | access to your own work; a bookmark says something is worth returning to, and | |
| 6 | its count is public.</p> | |
| 5 | access to your own work; a bookmark is a public vote to save access to another | |
| 6 | repo.</p> | |
| 7 | 7 | <ul class="repolist"> |
| 8 | 8 | {{range .Bookmarks}}<li> |
| 9 | 9 | <p class="title"><a href="/{{.Path}}">{{.Path}}</a> |
| @@ -11,6 +11,6 @@ its count is public.</p> | ||
| 11 | 11 | <span class="count">{{.Bookmarks}}</span></p> |
| 12 | 12 | {{if .Description}}<p class="desc">{{.Description}}</p>{{end}} |
| 13 | 13 | </li> |
| 14 | {{else}}<li class="empty">nothing bookmarked yet — open a repository and press Bookmark</li>{{end}} | |
| 14 | {{else}}<li class="empty">nothing bookmarked yet. open a repository and press Bookmark</li>{{end}} | |
| 15 | 15 | </ul> |
| 16 | 16 | {{end}} |
internal/web/templates/dashboard.html +3 −3
| @@ -39,9 +39,9 @@ | ||
| 39 | 39 | </div> |
| 40 | 40 | {{if .Reviews}}{{template "queue" dict "ID" "reviews" "Title" "Waiting on your review" "Items" .Reviews "Kind" "mrs" "Empty" "Nothing waiting on you"}}{{end}} |
| 41 | 41 | {{if .Assigned}}{{template "queue" dict "ID" "assigned" "Title" "Assigned to you" "Items" .Assigned "Kind" "issues" "Empty" "Nothing assigned to you"}}{{end}} |
| 42 | {{if .MRs}}{{template "queue" dict "ID" "mrs" "Title" "Open merge requests" "Items" .MRs "Kind" "mrs" "Empty" "No open merge requests" "Hint" "Yours anywhere, and every one in a repository you can write to."}}{{end}} | |
| 43 | {{if .Issues}}{{template "queue" dict "ID" "issues" "Title" "Open issues" "Items" .Issues "Kind" "issues" "Empty" "No open issues" "Hint" "Yours anywhere, and every one in a repository you can write to."}}{{end}} | |
| 44 | {{if not (or .Reviews .Assigned .MRs .Issues)}}<p class="none">Nothing open anywhere you can write to.</p>{{end}} | |
| 42 | {{if .MRs}}{{template "queue" dict "ID" "mrs" "Title" "Open merge requests" "Items" .MRs "Kind" "mrs" "Empty" "No open merge requests" "Hint" "Your MRs across all repos."}}{{end}} | |
| 43 | {{if .Issues}}{{template "queue" dict "ID" "issues" "Title" "Open issues" "Items" .Issues "Kind" "issues" "Empty" "No open issues" "Hint" "Your issues across all repos."}}{{end}} | |
| 44 | {{if not (or .Reviews .Assigned .MRs .Issues)}}<p class="none">Nothing open.</p>{{end}} | |
| 45 | 45 | </section> |
| 46 | 46 | |
| 47 | 47 | <aside class="feedcol" aria-label="Recent activity"> |
internal/web/templates/settings.html +8 −8
| @@ -44,7 +44,7 @@ | ||
| 44 | 44 | </form> |
| 45 | 45 | {{if .Branches}}<form method="post" action="{{$base}}" class="setform"> |
| 46 | 46 | <input type="hidden" name="field" value="default-branch"> |
| 47 | <div><label for="default-branch">Default branch</label><p class="hint">What a clone checks out and what CI builds on trigger.</p></div> | |
| 47 | <div><label for="default-branch">Default branch</label></div> | |
| 48 | 48 | <div><select id="default-branch" name="default-branch">{{$cur := .Repo.DefaultBranch}}{{range .Branches}}<option value="{{.Name}}"{{if eq .Name $cur}} selected{{end}}>{{.Name}}</option>{{end}}</select></div> |
| 49 | 49 | <div><button type="submit" class="btn">Save</button></div> |
| 50 | 50 | </form>{{end}} |
| @@ -53,7 +53,7 @@ | ||
| 53 | 53 | <section id="access"><h2>Access</h2> |
| 54 | 54 | <form method="post" action="{{$base}}" class="setform"> |
| 55 | 55 | <input type="hidden" name="field" value="visibility"> |
| 56 | <div><span class="fieldname">Visibility</span><p class="hint">Private repositories answer not found to everyone without access, including in search and on your profile.</p></div> | |
| 56 | <div><span class="fieldname">Visibility</span></div> | |
| 57 | 57 | <div class="check"> |
| 58 | 58 | <label><input type="radio" name="visibility" value="public"{{if eq .Repo.Visibility "public"}} checked{{end}}> Public</label> |
| 59 | 59 | <label><input type="radio" name="visibility" value="private"{{if eq .Repo.Visibility "private"}} checked{{end}}> Private</label> |
| @@ -62,7 +62,7 @@ | ||
| 62 | 62 | </form> |
| 63 | 63 | <form method="post" action="{{$base}}" class="setform"> |
| 64 | 64 | <input type="hidden" name="field" value="git-daemon"> |
| 65 | <div><label for="git-daemon">Serve over git://</label><p class="hint">Unauthenticated, unencrypted read access on port 9418. Public repositories only.</p></div> | |
| 65 | <div><label for="git-daemon">Serve over git://</label><p class="hint">Public repositories only.</p></div> | |
| 66 | 66 | <div class="check"><input type="checkbox" id="git-daemon" name="git-daemon" value="on"{{if .Repo.Settings.GitDaemon}} checked{{end}}></div> |
| 67 | 67 | <div><button type="submit" class="btn">Save</button></div> |
| 68 | 68 | </form> |
| @@ -72,13 +72,13 @@ | ||
| 72 | 72 | <p class="meta">Checked before a merge, in this order: checks, approvals, resolved threads, signatures.</p> |
| 73 | 73 | <form method="post" action="{{$base}}" class="setform"> |
| 74 | 74 | <input type="hidden" name="field" value="require-checks"> |
| 75 | <div><label for="require-checks">Required checks</label><p class="hint">A request waits until every CI job that would report on its head has succeeded.</p></div> | |
| 75 | <div><label for="require-checks">Required checks</label><p class="hint">Requires CI to succeed.</p></div> | |
| 76 | 76 | <div class="check"><input type="checkbox" id="require-checks" name="require-checks" value="on"{{if .Repo.Settings.RequireChecks}} checked{{end}}></div> |
| 77 | 77 | <div><button type="submit" class="btn">Save</button></div> |
| 78 | 78 | </form> |
| 79 | 79 | <form method="post" action="{{$base}}" class="setform"> |
| 80 | 80 | <input type="hidden" name="field" value="require-approvals"> |
| 81 | <div><label for="approvals">Approvals</label><p class="hint">Approvals from people with write access. Zero means none required.</p></div> | |
| 81 | <div><label for="approvals">Approvals</label><p class="hint">Approvals from anyone with write access. Zero means none required.</p></div> | |
| 82 | 82 | <div><input type="number" id="approvals" name="approvals" min="0" max="10" value="{{.Repo.Settings.RequireApprovals}}"></div> |
| 83 | 83 | <div><button type="submit" class="btn">Save</button></div> |
| 84 | 84 | </form> |
| @@ -90,7 +90,7 @@ | ||
| 90 | 90 | </form> |
| 91 | 91 | <form method="post" action="{{$base}}" class="setform"> |
| 92 | 92 | <input type="hidden" name="field" value="require-codeowners"> |
| 93 | <div><label for="require-codeowners">CODEOWNERS</label><p class="hint">Owners of every touched path must approve.</p></div> | |
| 93 | <div><label for="require-codeowners">CODEOWNERS</label><p class="hint">Code owners must approve.</p></div> | |
| 94 | 94 | <div class="check"><input type="checkbox" id="require-codeowners" name="require-codeowners" value="on"{{if .Repo.Settings.RequireCodeowners}} checked{{end}}></div> |
| 95 | 95 | <div><button type="submit" class="btn">Save</button></div> |
| 96 | 96 | </form> |
| @@ -151,12 +151,12 @@ | ||
| 151 | 151 | <section id="deps"><h2>Dependencies</h2> |
| 152 | 152 | <form method="post" action="{{$base}}" class="setform"> |
| 153 | 153 | <input type="hidden" name="field" value="deps"> |
| 154 | <div><label for="deps-enabled">Check for updates</label><p class="hint">Compares the manifests on <code>{{.Repo.DefaultBranch}}</code> against proxy.golang.org, npm, crates.io, and PyPI once a day, and tracks what is behind in an issue. Checking a private repository tells those registries what it depends on.</p></div> | |
| 154 | <div><label for="deps-enabled">Check for updates</label><p class="hint">Evaluates the manifests on <code>{{.Repo.DefaultBranch}}</code> and opens an issue. Go, NPM, Crates, and PyPI only.</p></div> | |
| 155 | 155 | <div class="check"><input type="checkbox" id="deps-enabled" name="deps" value="on"{{if .DepsEnabled}} checked{{end}}></div> |
| 156 | 156 | <div><button type="submit" class="btn">Save</button></div> |
| 157 | 157 | </form> |
| 158 | 158 | {{if .DepsEnabled}} |
| 159 | <p class="meta">Last checked {{if .Deps.LastCheck}}{{when .Deps.LastCheck}}{{else}}never{{end}}{{if .Deps.IssueNumber}} · tracked in <a href="/{{.Repo.OwnerName}}/{{.Repo.Name}}/issues/{{.Deps.IssueNumber}}">#{{.Deps.IssueNumber}}</a>{{end}}</p> | |
| 159 | <p class="meta">Last checked {{if .Deps.LastCheck}}{{when .Deps.LastCheck}}{{else}}never{{end}}{{if .Deps.IssueNumber}} · <a href="/{{.Repo.OwnerName}}/{{.Repo.Name}}/issues/{{.Deps.IssueNumber}}">#{{.Deps.IssueNumber}}</a>{{end}}</p> | |
| 160 | 160 | {{if .Deps.LastError}}<p class="error" role="alert">{{.Deps.LastError}}</p>{{end}} |
| 161 | 161 | {{if .Deps.Behind}}<div class="tablewrap"><table class="keys"> |
| 162 | 162 | <tr class="cols"><th scope="col">dependency</th><th scope="col">pinned</th><th scope="col">latest</th></tr> |