5 files changed,
25 insertions(+),
26 deletions(-)
Author:
Oleksandr Smirnov
olexsmir@gmail.com
Committed at:
2026-02-14 17:02:46 +0200
Authored at:
2026-02-14 16:41:13 +0200
Change ID:
tmpwyskmquztsyuvxtlpntxuonyxyyox
Parent:
deb6f00
M
web/templates/repo_commit.html
路路路 71 71 {{ $this := .commit.Hash }} 72 72 {{ $parent := index .parents 0 }} 73 73 {{ range .diff }} 74 - {{ $path := .Name.New }} 75 - {{ if not $path }}{{ $path = .Name.Old }}{{ end }} 76 - <div id="{{ $path }}"> 77 - <div class="diff"> 74 + {{ $path := .Name.New }} 75 + {{ if not $path }}{{ $path = .Name.Old }}{{ end }} 76 + <div id="{{ $path }}"> 77 + <div class="diff"> 78 78 {{ if .IsNew }} 79 79 <span class="diff-type diff-add">A</span> 80 80 {{ end }} 路路路 84 84 {{ if not (or .IsNew .IsDelete) }} 85 85 <span class="diff-type diff-mod">M</span> 86 86 {{ end }} 87 - {{ if .Name.Old }} 88 - <a href="/{{ $repo }}/blob/{{ $parent }}/{{ .Name.Old }}">{{ .Name.Old }}</a> 89 - {{ if .Name.New }} 87 + {{ if .Name.Old }} 88 + <a href="/{{ $repo }}/blob/{{ $parent }}/{{ .Name.Old }}">{{ .Name.Old }}</a> 89 + {{ if .Name.New }} 90 90 → 91 91 <a href="/{{ $repo }}/blob/{{ $this }}/{{ .Name.New }}">{{ .Name.New }}</a> 92 - {{ end }} 93 - {{ else }} 94 - <a href="/{{ $repo }}/blob/{{ $this }}/{{ .Name.New }}">{{ .Name.New }}</a> 95 - {{- end -}} 96 - {{ if .IsBinary }} 97 - <p>Not showing binary file.</p> 98 - {{ else }} 92 + {{ end }} 93 + {{ else }} 94 + <a href="/{{ $repo }}/blob/{{ $this }}/{{ .Name.New }}">{{ .Name.New }}</a> 95 + {{- end -}} 96 + {{ if .IsBinary }} 97 + <p>Not showing binary file.</p> 98 + {{ else }} 99 99 <pre> 100 - {{- range .TextFragments -}} 101 - <p>{{- .Header -}}</p> 102 - {{- range .Lines -}} 100 + {{- range .TextFragments -}} 101 + <p>{{- .Header -}}</p> 102 + {{- range .Lines -}} 103 103 {{- if eq .Op.String "+" -}} 104 104 <span class="diff-add">{{ .String }}</span> 105 105 {{- end -}} 路路路 109 109 {{- if eq .Op.String " " -}} 110 110 <span class="diff-noop">{{ .String }}</span> 111 111 {{- end -}} 112 - {{- end -}} 113 - {{- end -}} 114 - {{- end -}} 112 + {{- end -}} 113 + {{- end -}} 114 + {{- end -}} 115 115 </pre> 116 116 </div> 117 - </div> 117 + </div> 118 118 {{ end }} 119 119 </section> 120 120 </main>
M
web/templates/repo_file.html
路路路 2 2 <html> 3 3 <head> 4 4 {{ template "head" . }} 5 + <title>{{ .name }}: {{ .path }} ({{ .ref }})</title> 5 6 </head> 6 - {{ template "repo_header" . }} 7 7 <body> 8 + {{ template "repo_header" . }} 8 9 <main> 9 10 <p>{{ .path }} (<a class="muted" href="?raw=true">view raw</a>)</p> 10 11 <div class="file-wrapper">
M
web/templates/repo_log.html
路路路 4 4 {{ template "head" . }} 5 5 <title>{{ .name }}: log</title> 6 6 </head> 7 - {{ template "repo_header" . }} 8 7 <body> 8 + {{ template "repo_header" . }} 9 9 <main> 10 10 {{ $repo := .name }} 11 - 12 11 <table class="table log"> 13 12 <thead> 14 13 <tr class="nohover">