diff options
Diffstat (limited to 'templates/commit.qtpl')
| -rw-r--r-- | templates/commit.qtpl | 7 | 
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>  | 
