all repos

mugit @ 20a3418

馃惍 git server that your cow will love
3 files changed, 16 insertions(+), 19 deletions(-)
i dont like duplication
Author: Oleksandr Smirnov olexsmir@gmail.com
Committed at: 2026-03-06 16:04:31 +0200
Authored at: 2026-03-06 15:35:43 +0200
Change ID: rqrkorrltuvzpyulowtorxvowxvorror
Parent: f421981
M web/templates/repo_commit.html
路路路
        
        1
        +{{ define "_diff_type" }}

      
        
        2
        +{{ if .IsNew }}<span class="diff-type diff-add">A</span>

      
        
        3
        +{{ else if .IsDelete }}<span class="diff-type diff-del">D</span>

      
        
        4
        +{{ else }}<span class="diff-type diff-mod">M</span>{{ end }}

      
        
        5
        +{{ end }}

      
        
        6
        +

      
        1
        7
         {{ define "repo_commit" }}

      
        2
        8
         {{ $commit := .P.Diff.Commit }}

      
        3
        9
         {{ $diff := .P.Diff.Diff }}

      路路路
        65
        71
                       {{ $path := .Name.New }}

      
        66
        72
                       {{ if not $path }}{{ $path = .Name.Old }}{{ end }}

      
        67
        73
                       <tr>

      
        68
        
        -                <td class="diff-type">

      
        69
        
        -                  {{ if .IsNew }}<span class="diff-type diff-add">A</span>

      
        70
        
        -                  {{ else if .IsDelete }}<span class="diff-type diff-del">D</span>

      
        71
        
        -                  {{ else }}<span class="diff-type diff-mod">M</span>{{ end }}

      
        72
        
        -                </td>

      
        
        74
        +                <td class="diff-type">{{ template "_diff_type" . }}</td>

      
        73
        75
                         <td class="fill">

      
        74
        76
                           <a href="#{{ $path }}">

      
        75
        77
                             {{ if .IsRename }}{{ .Name.Old }} &#8594; {{ .Name.New }}

      路路路
        93
        95
                 {{ if not $path }}{{ $path = .Name.Old }}{{ end }}

      
        94
        96
                 <div id="{{ $path }}">

      
        95
        97
                   <div class="diff">

      
        96
        
        -            {{ if .IsNew }}<span class="diff-type diff-add">A</span>

      
        97
        
        -            {{ else if .IsDelete }}<span class="diff-type diff-del">D</span>

      
        98
        
        -            {{ else }}<span class="diff-type diff-mod">M</span>{{ end }}

      
        
        98
        +            {{ template "_diff_type" . }}

      
        99
        99
         

      
        100
        100
                     {{ if .IsNew }}<a href="/{{ $.RepoName }}/blob/{{ $this }}/{{ .Name.New }}">{{ .Name.New }}</a>{{ else }}

      
        101
        101
                     {{ if $parent }}<a href="/{{ $.RepoName }}/blob/{{ $parent }}/{{ .Name.New }}">{{ .Name.New }}</a>

      路路路
        103
        103
                     {{ if .IsRename }}&#8594;<a href="/{{ $.RepoName }}/blob/{{ $this }}/{{ .Name.New }}">{{ .Name.New }}</a>{{ end }}

      
        104
        104
                     {{ end }}

      
        105
        105
         

      
        106
        
        -            {{ if .IsBinary }}

      
        107
        
        -            <p>Not showing binary file.</p>

      
        
        106
        +            {{ if .IsBinary }}<p>Not showing binary file.</p>

      
        108
        107
                     {{ else }}

      
        109
        108
                     <pre>

      
        110
        109
                       {{- range .TextFragments -}}

      
M web/templates/repo_index.html
路路路
        35
        35
                 <div class="repo-index-side">

      
        36
        36
                   <h2>Clone urls</h2>

      
        37
        37
                   <pre>https://{{.Meta.Host}}/{{.RepoName}}</pre>

      
        38
        
        -          {{ if .Meta.SSHEnabled }}<pre>{{ .P.SSHUser }}@{{.Meta.Host}}:{{.RepoName}}</pre>{{end}}

      
        39
        
        -          {{- if .P.IsMirror -}}

      
        
        38
        +          {{ if .Meta.SSHEnabled }}<pre>{{.P.SSHUser}}@{{.Meta.Host}}:{{.RepoName}}</pre>{{end}}

      
        
        39
        +          {{ if .P.IsMirror }}

      
        40
        40
                   <br>

      
        41
        41
                   <h2>Mirror status</h2>

      
        42
        42
                   <p>

      
        43
        43
                     Last updated {{ humanizeRelTime .P.MirrorLastSync }} from:

      
        44
        44
                     <a href="{{.P.MirrorURL}}" target="_blank">{{.P.MirrorURL}}</a>

      
        45
        45
                   </p>

      
        46
        
        -          {{- end}}

      
        
        46
        +          {{ end }}

      
        47
        47
                 </div>

      
        48
        48
               </section>

      
        49
        
        -      {{ end }}

      
        50
        49
         

      
        51
        
        -      {{- if .P.Readme }}

      
        52
        
        -      <article class="readme">{{- .P.Readme -}}</article>

      
        53
        
        -      {{- end -}}

      
        
        50
        +      {{ if .P.Readme }}<article class="readme">{{.P.Readme}}</article>{{ end }}

      
        
        51
        +      {{ end }}

      
        54
        52
             </main>

      
        55
        53
           </body>

      
        56
        54
         </html>

      
M web/templates/repo_log.html
路路路
        47
        47
                 </tbody>

      
        48
        48
               </table>

      
        49
        49
               <div class="center">

      
        50
        
        -        {{- if .P.NextAfter }}

      
        
        50
        +        {{ if .P.NextAfter }}

      
        51
        51
                 <a href="?after={{ urlencode .P.NextAfter }}">[load more]</a>

      
        52
        
        -        {{- end }}

      
        
        52
        +        {{ end }}

      
        53
        53
               </div>

      
        54
        54
             </main>

      
        55
        55
           </body>