diff options
| author | Jeff Carr <[email protected]> | 2025-09-27 01:44:01 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-09-27 02:15:07 -0500 |
| commit | c078811dcb037b0482400a68f074cc8d3108ae43 (patch) | |
| tree | 756a9374faca42e4dffa29c65e5764e3ea7d5256 /humanForgedTable.go | |
| parent | 330c011b4d16cc4571f46172c047ba4b057a43cd (diff) | |
better forged table
Diffstat (limited to 'humanForgedTable.go')
| -rw-r--r-- | humanForgedTable.go | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/humanForgedTable.go b/humanForgedTable.go index b727f2b..c9a5e17 100644 --- a/humanForgedTable.go +++ b/humanForgedTable.go @@ -18,11 +18,28 @@ func (f *Forge) makeForgedTable(pb *gitpb.Repos) *gitpb.ReposTable { var col *gitpb.RepoAnyFunc col = t.AddMasterVersion() - col.Width = 15 + col.Width = 7 col = t.AddMasterBranchName() col.Width = 10 + col = t.AddStringFunc("blah", func(r *gitpb.Repo) string { + if r.Tags == nil { + return "tags=nil" + } + if r.Tags.Master == nil { + return "mtag=nil" + } + return r.Tags.Master.Refname + }) + col.Width = 12 + + col = t.AddNamespace() + col.Width = 32 + + col = t.AddURL() + col.Width = 32 + col = t.AddFullPath() col.Width = -1 return t |
