diff options
author | John Olheiser <john.olheiser@gmail.com> | 2020-06-05 13:44:54 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-06-05 14:44:54 -0400 |
commit | ac0741801101d56b6bccd1089ffedf2b3480758b (patch) | |
tree | 1d4b05082769fd64c28cdf73e4bf2206ddae1624 | |
parent | 48f24c7b3257f834c38f3f81c2b39a6dd2f9ff42 (diff) | |
download | gitea-ac0741801101d56b6bccd1089ffedf2b3480758b.tar.gz gitea-ac0741801101d56b6bccd1089ffedf2b3480758b.zip |
Add compare link to releases (#11752)
Signed-off-by: jolheiser <john.olheiser@gmail.com>
Co-authored-by: Lauris BH <lauris@nix.lv>
-rw-r--r-- | options/locale/locale_en-US.ini | 3 | ||||
-rw-r--r-- | templates/repo/release/list.tmpl | 4 |
2 files changed, 4 insertions, 3 deletions
diff --git a/options/locale/locale_en-US.ini b/options/locale/locale_en-US.ini index 534520d2d2..f2e58b95b8 100644 --- a/options/locale/locale_en-US.ini +++ b/options/locale/locale_en-US.ini @@ -1660,7 +1660,8 @@ release.draft = Draft release.prerelease = Pre-Release release.stable = Stable release.edit = edit -release.ahead = <strong>%d</strong> commits to %s since this release +release.ahead.commits = <strong>%d</strong> commits +release.ahead.target = to %s since this release release.source_code = Source Code release.new_subheader = Releases organize project versions. release.edit_subheader = Releases organize project versions. diff --git a/templates/repo/release/list.tmpl b/templates/repo/release/list.tmpl index d0b160a1c0..baef2c1cee 100644 --- a/templates/repo/release/list.tmpl +++ b/templates/repo/release/list.tmpl @@ -64,8 +64,8 @@ Ghost {{end}} </span> - {{if .CreatedUnix}}<span class="time">{{TimeSinceUnix .CreatedUnix $.Lang}}</span>{{end}} - <span class="ahead">{{$.i18n.Tr "repo.release.ahead" .NumCommitsBehind .Target | Str2html}}</span> + {{if .CreatedUnix}}<span class="time">{{TimeSinceUnix .CreatedUnix $.Lang}}</span> | {{end}} + <span class="ahead"><a href="{{$.RepoLink}}/compare/{{.TagName | EscapePound}}...{{.Target}}">{{$.i18n.Tr "repo.release.ahead.commits" .NumCommitsBehind | Str2html}}</a> {{$.i18n.Tr "repo.release.ahead.target" .Target}}</span> </p> <div class="markdown desc"> {{Str2html .Note}} |