From 27400b0fce5d4ef3b7fd5ef4d25bac8f00754e33 Mon Sep 17 00:00:00 2001 From: "Gabriel A. Giovanini" Date: Sat, 15 Feb 2025 17:33:24 +0100 Subject: feat: Add wrapper for commit Add a wrapper to the commit log that also contains possible reference. This will be useful once to later display the reference in the commit log. --- templates/gititemsummary.qtpl | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'templates/gititemsummary.qtpl') diff --git a/templates/gititemsummary.qtpl b/templates/gititemsummary.qtpl index f2de5be..5d07680 100644 --- a/templates/gititemsummary.qtpl +++ b/templates/gititemsummary.qtpl @@ -1,12 +1,11 @@ {% import "github.com/go-git/go-git/v5/plumbing" %} -{% import "github.com/go-git/go-git/v5/plumbing/object" %} {% import "git.gabrielgio.me/cerrado/pkg/git" %} {% code type GitItemSummaryPage struct { Tags []*git.TagReference Branches []*plumbing.Reference - Commits []*object.Commit + Commits []*git.CommitReference } %} @@ -39,7 +38,7 @@ type GitItemSummaryPage struct {
{% for _, c := range g.Commits %} - {%= Commit(name, c, false) %} + {%= Commit(name, c.Commit(), false) %} {% endfor %}
-- cgit v1.2.3