refactor!: vertical render & UI/UX fixes

See coop-cloud/abra#454
This commit is contained in:
2024-12-28 15:30:43 +01:00
committed by decentral1se
parent b6573720ec
commit 97959ef5da
17 changed files with 352 additions and 184 deletions

View File

@ -63,7 +63,7 @@ var AppServicesCommand = &cobra.Command{
log.Fatal(err)
}
headers := []string{"SERVICE (SHORT)", "SERVICE (LONG)", "IMAGE"}
headers := []string{"SERVICE (SHORT)", "SERVICE (LONG)"}
table.Headers(headers...)
var rows [][]string
@ -80,7 +80,6 @@ var AppServicesCommand = &cobra.Command{
row := []string{
serviceShortName,
serviceLongName,
formatter.RemoveSha(container.Image),
}
rows = append(rows, row)
@ -89,7 +88,9 @@ var AppServicesCommand = &cobra.Command{
table.Rows(rows...)
if len(rows) > 0 {
fmt.Println(table)
if err := formatter.PrintTable(table); err != nil {
log.Fatal(err)
}
}
},
}