templates: fix 404 and 500
This commit is contained in:
parent
f04137f841
commit
7d99afc5cd
4 changed files with 14 additions and 4 deletions
|
@ -1,7 +1,9 @@
|
|||
{{ define "404" }}
|
||||
<html>
|
||||
<title>404</title>
|
||||
{{ template "header" . }}
|
||||
{{ template "head" . }}
|
||||
<body>
|
||||
404 — nothing like that here
|
||||
</body>
|
||||
</html>
|
||||
{{ end }}
|
||||
|
|
|
@ -1,3 +1,4 @@
|
|||
{{ define "500" }}
|
||||
<html>
|
||||
<title>500</title>
|
||||
{{ template "header" . }}
|
||||
|
@ -5,3 +6,4 @@
|
|||
500 — something broke!
|
||||
</body>
|
||||
</html>
|
||||
{{ end }}
|
||||
|
|
|
@ -1,9 +1,10 @@
|
|||
{{ define "nav" }}
|
||||
<nav>
|
||||
<ul>
|
||||
<li>some
|
||||
<li>thing
|
||||
<li>here
|
||||
<li><a href="/">all repos</a>
|
||||
<li><a href="/{{ .name }}">{{ .name }}</a>
|
||||
<li><a href="/{{ .name }}/tree/{{ .ref }}/">tree</a>
|
||||
<li><a href="/{{ .name }}/log/{{ .ref }}">log</a>
|
||||
</ul>
|
||||
</nav>
|
||||
{{ end }}
|
||||
|
|
|
@ -44,6 +44,11 @@
|
|||
{{ end }}
|
||||
{{ end }}
|
||||
</table>
|
||||
<article>
|
||||
<pre>
|
||||
{{- if .readme }}{{ .readme }}{{- end -}}
|
||||
</pre>
|
||||
</article>
|
||||
</main>
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Reference in a new issue