mygit

[UNMAINTAINED] A cgit/webgit alternative, written in Rust
Log | Files | Refs | README | LICENSE

commit e40fe7f011c0e49d519b8cf34b507378116e8565
parent 645bd12e06779d7869e167aa9627ad2e3f5768d6
Author: Johann150 <johann@qwertqwefsday.eu>
Date:   Mon, 28 Jun 2021 20:47:47 +0200

show separate committer if different

The committer is only shown if their name or their email address
differ from the respective data of the commit author.

Diffstat:
Mtemplates/commit.html | 4++++
1 file changed, 4 insertions(+), 0 deletions(-)

diff --git a/templates/commit.html b/templates/commit.html @@ -10,6 +10,10 @@ {% endfor %} <b>Author:</b> {{commit.author().name().unwrap()}} &lt;<a href="mailto:{{commit.author().email().unwrap()}}">{{commit.author().email().unwrap()}}</a>&gt; <br> + {% if commit.author().name() != commit.committer().name() || commit.author().email() != commit.committer().email() %} + <b>Committer:</b> {{commit.committer().name().unwrap()}} &lt;<a href="mailto:{{commit.committer().email().unwrap()}}">{{commit.committer().email().unwrap()}}</a>&gt; + <br> + {% endif %} <b>Date:</b> {{commit.time()|format_datetime("%c %z")}} <br> {% let stats = diff.stats().unwrap() %}