templates/repo.html (view raw)
1{{ define "repo" }}
2<html>
3 <title>{{ .name }}
4 {{ if .parent }}
5 — {{ .parent }}
6 {{ end }}
7 </title>
8{{ template "head" . }}
9
10{{ template "repoheader" . }}
11
12 <body>
13 {{ template "nav" . }}
14 <main>
15 {{ $repo := .name }}
16 <div class="log">
17 {{ range .commits }}
18 <div>
19 <div><a href="/{{ $repo }}/commit/{{ .Hash.String }}">{{ slice .Hash.String 0 8 }}</a></div>
20 <div>{{ .Author.When.Format "Mon, 02 Jan 2006 15:04:05 -0700" }}</div>
21 <pre>{{ .Message }}</pre>
22 </div>
23 <div class="commit-info">{{ .Author.Name }} <span class="commit-email">{{ .Author.Email }}</span></div>
24 {{ end }}
25 </div>
26 <article class="readme">
27 <pre>
28 {{- if .readme }}{{ .readme }}{{- end -}}
29 </pre>
30 </article>
31 </main>
32 </body>
33</html>
34{{ end }}