add description field to ListItem interface

This commit is contained in:
Jesse Duffield 2020-08-22 10:14:53 +10:00
parent 63209ef71e
commit 8da93fd762
9 changed files with 36 additions and 4 deletions

View file

@ -21,10 +21,6 @@ func (c *Commit) ShortSha() string {
return c.Sha[:8]
}
func (c *Commit) NameWithSha() string {
return fmt.Sprintf("%s %s", c.Sha[:7], c.Name)
}
func (c *Commit) RefName() string {
return c.Sha
}
@ -32,3 +28,7 @@ func (c *Commit) RefName() string {
func (c *Commit) ID() string {
return c.RefName()
}
func (c *Commit) Description() string {
return fmt.Sprintf("%s %s", c.Sha[:7], c.Name)
}