Skip to content

Commit

Permalink
Display latest sync time for pull mirrors on the repo page (#28712)
Browse files Browse the repository at this point in the history
Fixes #25168

---------

Co-authored-by: delvh <dev.lh@web.de>
  • Loading branch information
dsseng and delvh authored Jan 15, 2024
1 parent 3793ec4 commit 2d343f8
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions templates/repo/header.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,13 @@
<div class="repo-icon" data-tooltip-content="{{ctx.Locale.Tr "repo.desc.template"}}">{{svg "octicon-repo-template" 18}}</div>
{{end}}
</div>
{{if $.PullMirror}}
<div class="fork-flag">
{{ctx.Locale.Tr "repo.mirror_from"}}
<a target="_blank" rel="noopener noreferrer" href="{{$.PullMirror.RemoteAddress}}">{{$.PullMirror.RemoteAddress}}</a>
{{if $.PullMirror.UpdatedUnix}}{{ctx.Locale.Tr "repo.mirror_sync"}} {{TimeSinceUnix $.PullMirror.UpdatedUnix ctx.Locale}}{{end}}
</div>
{{end}}
</div>
{{if not (or .IsBeingCreated .IsBroken)}}
<div class="repo-buttons">
Expand Down

0 comments on commit 2d343f8

Please sign in to comment.