chore: hide STORE column in 'uc images' output if all machines use containerd image store

This commit is contained in:
Pasha Sviderski
2026-04-23 17:52:45 +10:00
parent 50057c42e0
commit c38d916dbb
+8
View File
@@ -260,6 +260,14 @@ func formatImageTable(rows []imageRow) string {
columns[5].hide = true columns[5].hide = true
} }
// Hide the "STORE" column if all machines use the containerd store.
hasNonContainerd := slices.ContainsFunc(rows, func(r imageRow) bool {
return r.store != "containerd"
})
if !hasNonContainerd {
columns[6].hide = true
}
t := tui.NewTable() t := tui.NewTable()
var headers []string var headers []string