aboutsummaryrefslogtreecommitdiff
path: root/templates/commit.qtpl
diff options
context:
space:
mode:
authorGabriel A. Giovanini <mail@gabrielgio.me>2024-07-21 17:55:51 +0200
committerGabriel A. Giovanini <mail@gabrielgio.me>2024-07-21 17:56:27 +0200
commit8a237e0cfea615747976d03ed1a6b1a932e5fa86 (patch)
tree6fc4eb3159d502aa3a83b3ea3ea6a2b7bad2955a /templates/commit.qtpl
parent64d9bcc4e567a0f816a0388bf740baa4c01d2323 (diff)
downloadcerrado-8a237e0cfea615747976d03ed1a6b1a932e5fa86.tar.gz
cerrado-8a237e0cfea615747976d03ed1a6b1a932e5fa86.tar.bz2
cerrado-8a237e0cfea615747976d03ed1a6b1a932e5fa86.zip
feat: Add tar.gz link to commit pagev0.0.13
Diffstat (limited to 'templates/commit.qtpl')
-rw-r--r--templates/commit.qtpl7
1 files changed, 6 insertions, 1 deletions
diff --git a/templates/commit.qtpl b/templates/commit.qtpl
index 3070172..2b58864 100644
--- a/templates/commit.qtpl
+++ b/templates/commit.qtpl
@@ -1,11 +1,16 @@
{% import "github.com/go-git/go-git/v5/plumbing/object" %}
-{% func Commit(name string, c *object.Commit) %}
+{% 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>
</div>
+ {% if showTar %}
+ <div class="col-md text-md-center">
+ <a title="tar.gz for {%s c.Hash.String() %}" href="/{%s name %}/archive/{%s c.Hash.String() %}.tar.gz">tar.gz</a>
+ </div>
+ {% endif %}
<div class="col-md text-md-end">
<a title="{%s c.Committer.Email %}" href="mailto:{%s c.Committer.Email %}">{%s c.Committer.Name %}</a>
</div>