diff options
author | Runxi Yu <me@runxiyu.org> | 2025-03-05 10:34:24 +0800 |
---|---|---|
committer | Runxi Yu <me@runxiyu.org> | 2025-03-05 10:34:24 +0800 |
commit | d0e00c2879ddad6f7238b52f9720475d4068d759 (patch) | |
tree | 9167a5a0bbed1a05207de8955123612e62691980 /templates | |
parent | render_readme: Rename (diff) | |
download | forge-d0e00c2879ddad6f7238b52f9720475d4068d759.tar.gz forge-d0e00c2879ddad6f7238b52f9720475d4068d759.tar.zst forge-d0e00c2879ddad6f7238b52f9720475d4068d759.zip |
repo/contrib/one: Diff against merge base
Diffstat (limited to 'templates')
-rw-r--r-- | templates/repo_contrib_one.tmpl | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/templates/repo_contrib_one.tmpl b/templates/repo_contrib_one.tmpl index dca8a8f..1083e8c 100644 --- a/templates/repo_contrib_one.tmpl +++ b/templates/repo_contrib_one.tmpl @@ -39,11 +39,15 @@ <th scope="row">Destination branch</th> <td>{{ .mr_destination_branch }}</td> </tr> + <tr> + <th scope="row">Merge base</th> + <td>{{ .merge_base.ID.String }}</td> + </tr> </tbody> </table> </div> <div class="padding-wrapper"> - {{ $destination_commit := .destination_commit }} + {{ $merge_base := .merge_base }} {{ $source_commit := .source_commit }} {{ range .file_patches }} <div class="file-patch toggle-on-wrapper"> @@ -53,7 +57,7 @@ {{ if eq .From.Path "" }} --- /dev/null {{ else }} - --- a/<a href="../../tree/{{ .From.Path }}?commit={{ $destination_commit.Hash }}">{{ .From.Path }}</a> {{ .From.Mode }} + --- a/<a href="../../tree/{{ .From.Path }}?commit={{ $merge_base.Hash }}">{{ .From.Path }}</a> {{ .From.Mode }} {{ end }} <br /> {{ if eq .To.Path "" }} |