diff options
author | Michael Muré <batolettre@gmail.com> | 2018-09-15 20:30:31 +0200 |
---|---|---|
committer | Michael Muré <batolettre@gmail.com> | 2018-09-15 20:30:31 +0200 |
commit | bfb5e96aab9e78f05942151060cc92fdaa32bedd (patch) | |
tree | ddac4640aa1b43e13dc466cad6bbaed49f172fd9 /termui/bug_table.go | |
parent | 6b732d4535fc31e37485c7b496f2bbe0c854f661 (diff) | |
download | git-bug-bfb5e96aab9e78f05942151060cc92fdaa32bedd.tar.gz |
commands: git bug comment now show the comments of a bug
Diffstat (limited to 'termui/bug_table.go')
-rw-r--r-- | termui/bug_table.go | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/termui/bug_table.go b/termui/bug_table.go index 8c32a631..4ac2ce83 100644 --- a/termui/bug_table.go +++ b/termui/bug_table.go @@ -297,12 +297,12 @@ func (bt *bugTable) render(v *gocui.View, maxX int) { person = create.Author } - id := text.LeftPaddedString(snap.HumanId(), columnWidths["id"], 2) - status := text.LeftPaddedString(snap.Status.String(), columnWidths["status"], 2) - title := text.LeftPaddedString(snap.Title, columnWidths["title"], 2) - author := text.LeftPaddedString(person.Name, columnWidths["author"], 2) - summary := text.LeftPaddedString(snap.Summary(), columnWidths["summary"], 2) - lastEdit := text.LeftPaddedString(humanize.Time(snap.LastEditTime()), columnWidths["lastEdit"], 2) + id := text.LeftPadMaxLine(snap.HumanId(), columnWidths["id"], 2) + status := text.LeftPadMaxLine(snap.Status.String(), columnWidths["status"], 2) + title := text.LeftPadMaxLine(snap.Title, columnWidths["title"], 2) + author := text.LeftPadMaxLine(person.Name, columnWidths["author"], 2) + summary := text.LeftPadMaxLine(snap.Summary(), columnWidths["summary"], 2) + lastEdit := text.LeftPadMaxLine(humanize.Time(snap.LastEditTime()), columnWidths["lastEdit"], 2) fmt.Fprintf(v, "%s %s %s %s %s %s\n", colors.Cyan(id), @@ -318,12 +318,12 @@ func (bt *bugTable) render(v *gocui.View, maxX int) { func (bt *bugTable) renderHeader(v *gocui.View, maxX int) { columnWidths := bt.getColumnWidths(maxX) - id := text.LeftPaddedString("ID", columnWidths["id"], 2) - status := text.LeftPaddedString("STATUS", columnWidths["status"], 2) - title := text.LeftPaddedString("TITLE", columnWidths["title"], 2) - author := text.LeftPaddedString("AUTHOR", columnWidths["author"], 2) - summary := text.LeftPaddedString("SUMMARY", columnWidths["summary"], 2) - lastEdit := text.LeftPaddedString("LAST EDIT", columnWidths["lastEdit"], 2) + id := text.LeftPadMaxLine("ID", columnWidths["id"], 2) + status := text.LeftPadMaxLine("STATUS", columnWidths["status"], 2) + title := text.LeftPadMaxLine("TITLE", columnWidths["title"], 2) + author := text.LeftPadMaxLine("AUTHOR", columnWidths["author"], 2) + summary := text.LeftPadMaxLine("SUMMARY", columnWidths["summary"], 2) + lastEdit := text.LeftPadMaxLine("LAST EDIT", columnWidths["lastEdit"], 2) fmt.Fprintf(v, "\n") fmt.Fprintf(v, "%s %s %s %s %s %s\n", id, status, title, author, summary, lastEdit) |