1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
{{define "content"}}
{{$p := .Data.Page}}
<h3>Repository settings</h3>
<form method="post" action="/{{$p.Repo.Path}}/settings" class="twocol">
<div>
<label>Description <input name="description" value="{{$p.Repo.Description}}" maxlength="200"></label>
<label>Tags <input name="tags" value="{{range $i, $t := $p.Repo.Tags}}{{if $i}}, {{end}}{{$t}}{{end}}" placeholder="Up to three comma-separated topics"></label>
<div class="actions"><button class="btn primary">Save ▸</button></div>
</div>
<div>
<span class="legend">Visibility</span>
<label class="radio"><input type="radio" name="visibility" value="public"{{if not (or $p.Repo.Private $p.Repo.Unlisted)}} checked{{end}}> Public<small>Shown on your profile and listed in the public index</small></label>
<label class="radio"><input type="radio" name="visibility" value="unlisted"{{if $p.Repo.Unlisted}} checked{{end}}> Unlisted<small>Visible to anyone who knows the URL, but not shown on your profile</small></label>
<label class="radio"><input type="radio" name="visibility" value="private"{{if $p.Repo.Private}} checked{{end}}> Private<small>Only visible to you</small></label>
</div>
</form>
<h3>Rename</h3>
<form method="post" action="/{{$p.Repo.Path}}/rename" class="stack">
<label>New name <input name="name" value="{{$p.Repo.Name}}" required pattern="[a-z0-9][a-z0-9_.-]{0,38}"></label>
<small>Old URLs stop working, forks and pull requests follow the repository.</small>
<div class="actions left"><button class="btn primary">Rename ▸</button></div>
</form>
<h3>Transfer</h3>
<form method="post" action="/{{$p.Repo.Path}}/transfer" class="stack">
<label>New owner <input name="owner" placeholder="~someone" required></label>
<label>Type <code>{{$p.Repo.Name}}</code> to confirm <input name="confirm" required></label>
<div class="actions left"><button class="btn danger">Transfer repository ▸</button></div>
</form>
<h3>Archive</h3>
<p>{{if $p.Repo.Archived}}This repository is archived, nobody can push, open pull requests or comment.{{else}}Archiving makes the repository read only. Nobody can push, open pull requests or comment until it is unarchived.{{end}}</p>
<form method="post" action="/{{$p.Repo.Path}}/archive"><button class="btn">{{if $p.Repo.Archived}}Unarchive ▸{{else}}Archive ▸{{end}}</button></form>
<h3>Collaborators</h3>
<p>Collaborators can push, read the repository if it is private, and merge pull requests. Only you can change settings or delete it.</p>
{{if .Data.Collaborators}}<table class="keys">{{range .Data.Collaborators}}<tr><td><a href="/~{{.Name}}">~{{.Name}}</a></td><td><form method="post" action="/{{$p.Repo.Path}}/collaborators"><input type="hidden" name="remove" value="{{.ID}}"><button class="btn danger">Remove</button></form></td></tr>{{end}}</table>{{end}}
<form method="post" action="/{{$p.Repo.Path}}/collaborators" class="stack">
<label>Username <input name="name" placeholder="~someone" required></label>
<div class="actions left"><button class="btn primary">Add collaborator ▸</button></div>
</form>
<h3>Delete repository</h3>
<form method="post" action="/{{$p.Repo.Path}}/delete" class="stack">
<p>This permanently removes the repository and its history from the server.</p>
<label>Type <code>{{$p.Repo.Name}}</code> to confirm <input name="confirm" required></label>
<div class="actions left"><button class="btn danger">Delete repository ▸</button></div>
</form>
{{end}}
|