{{define "content" -}} {{template "repohead" .}} {{- $r := .Repo}}{{$kind := .Kind}}

{{if eq $kind "tags"}}{{template "icon" "tag"}}{{else}}{{template "icon" "branch"}}{{end}}{{len .Refs}} {{if eq (len .Refs) 1}}{{slice $kind 0 (len $kind | dec)}}{{else}}{{$kind}}{{end}}

{{- if .Refs}}
    {{- range .Refs}}{{$href := $r.CommitHref .Hash}}
  1. {{if eq $kind "tags"}}{{template "icon" "tag"}}{{else}}{{template "icon" "branch"}}{{end}}
    {{- if and (eq $kind "branches") (eq .Name $r.DefaultBranch)}}{{.Name}}default {{- else if and (eq $kind "tags") ($r.Release .Name)}}{{.Name}} {{- else}}{{.Name}}{{end}} {{if $href}}{{.Subject}}{{else}}{{.Subject}}{{end}}
    {{template "sha" (dict "R" $r "Hash" .Hash "Href" $href)}}
  2. {{- end}}
{{- else}}

{{template "icon" (or (and (eq $kind "tags") "tag") "branch")}}None yet.

{{- end}}
{{- if eq $kind "branches"}}

Only the default branch is browsable here. Clone the repository for the others.

{{end}} {{- end}}