aboutsummaryrefslogtreecommitdiff
path: root/templates/commit.qtpl
diff options
context:
space:
mode:
Diffstat (limited to 'templates/commit.qtpl')
-rw-r--r--templates/commit.qtpl6
1 files changed, 4 insertions, 2 deletions
diff --git a/templates/commit.qtpl b/templates/commit.qtpl
index dc6eae4..ea2f144 100644
--- a/templates/commit.qtpl
+++ b/templates/commit.qtpl
@@ -1,10 +1,12 @@
+{% import "git.gabrielgio.me/cerrado/pkg/humanize" %}
{% import "github.com/go-git/go-git/v5/plumbing/object" %}
{% func Commit(name string, c *object.Commit, showTar bool) %}
<div class="row event">
<div class="row">
<div class="col-md">
- <a title="{%s c.Hash.String() %}" href="/{%s name %}/commit/{%s c.Hash.String() %}/">{%s c.Hash.String()[0:8] %}</a>
+ <a title="{%s c.Hash.String() %}" href="/{%s name %}/commit/{%s c.Hash.String() %}/">{%s c.Hash.String()[0:8] %}</a> —
+ <a title="{%s c.Committer.Email %}" href="mailto:{%s c.Author.Email %}">{%s c.Author.Name %}</a>
</div>
{% if showTar %}
<div class="col-md text-md-center">
@@ -12,7 +14,7 @@
</div>
{% endif %}
<div class="col-md text-md-end">
- <a title="{%s c.Committer.Email %}" href="mailto:{%s c.Author.Email %}">{%s c.Author.Name %}</a>
+ <a title="{%s c.Author.When.Format("2006-01-02 15:04:05 UTC")%}">{%s humanize.Time(c.Author.When) %}</a>
</div>
</div>
<div class="code-view">