Skip to content

Commit 13166b3

Browse files
added colour support to remaining sub commands
1 parent 2220ea8 commit 13166b3

File tree

11 files changed

+21
-1
lines changed

11 files changed

+21
-1
lines changed

pkg/plugin/capabilities.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,9 @@ func Capabilities(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags,
6565
builder.SetFlagsFrom(commonFlagList)
6666

6767
table := Table{}
68-
builder.Table = &table
68+
table.ColourOutput = commonFlagList.outputAsColour
6969

70+
builder.Table = &table
7071
builder.ShowTreeView = commonFlagList.showTreeView
7172

7273
if err := builder.Build(&loopinfo); err != nil {

pkg/plugin/commands.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ func Commands(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args
7373
builder.SetFlagsFrom(commonFlagList)
7474

7575
table := Table{}
76+
table.ColourOutput = commonFlagList.outputAsColour
77+
7678
builder.Table = &table
7779
builder.ShowTreeView = commonFlagList.showTreeView
7880

pkg/plugin/environment.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,8 @@ func Environment(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, a
7373
}
7474

7575
table := Table{}
76+
table.ColourOutput = commonFlagList.outputAsColour
77+
7678
builder.Table = &table
7779
builder.ShowTreeView = commonFlagList.showTreeView
7880
if err := builder.Build(&loopinfo); err != nil {

pkg/plugin/image.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ func Image(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args []
7171
}
7272

7373
table := Table{}
74+
table.ColourOutput = commonFlagList.outputAsColour
75+
7476
builder.Table = &table
7577
builder.CommonFlags = commonFlagList
7678
builder.Connection = &connect

pkg/plugin/ip.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ func IP(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args []str
4848
return err
4949
}
5050
table := Table{}
51+
table.ColourOutput = commonFlagList.outputAsColour
5152
table.SetHeader(
5253
"NAME", "IP",
5354
)

pkg/plugin/lifecycle.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ func Lifecycle(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, arg
7272
builder.SetFlagsFrom(commonFlagList)
7373

7474
table := Table{}
75+
table.ColourOutput = commonFlagList.outputAsColour
76+
7577
builder.Table = &table
7678
builder.ShowTreeView = commonFlagList.showTreeView
7779

pkg/plugin/ports.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,8 @@ func Ports(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args []
6868
builder.SetFlagsFrom(commonFlagList)
6969

7070
table := Table{}
71+
table.ColourOutput = commonFlagList.outputAsColour
72+
7173
builder.Table = &table
7274
builder.ShowTreeView = commonFlagList.showTreeView
7375

pkg/plugin/probes.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,8 @@ func Probes(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args [
7777
builder.SetFlagsFrom(commonFlagList)
7878

7979
table := Table{}
80+
table.ColourOutput = commonFlagList.outputAsColour
81+
8082
builder.Table = &table
8183
builder.ShowTreeView = commonFlagList.showTreeView
8284

pkg/plugin/restarts.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,8 @@ func Restarts(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args
6767
builder.SetFlagsFrom(commonFlagList)
6868

6969
table := Table{}
70+
table.ColourOutput = commonFlagList.outputAsColour
71+
7072
builder.Table = &table
7173
builder.ShowTreeView = commonFlagList.showTreeView
7274

pkg/plugin/security.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,8 @@ func Security(cmd *cobra.Command, kubeFlags *genericclioptions.ConfigFlags, args
6767
builder.SetFlagsFrom(commonFlagList)
6868

6969
table := Table{}
70+
table.ColourOutput = commonFlagList.outputAsColour
71+
7072
builder.Table = &table
7173
builder.ShowTreeView = commonFlagList.showTreeView
7274

0 commit comments

Comments
 (0)