Skip to content
This repository has been archived by the owner on Jul 30, 2023. It is now read-only.

Commit

Permalink
Merge pull request #86 from prune998/prune/ctx-no-color
Browse files Browse the repository at this point in the history
remove ctx and ns subcommand from colorization
  • Loading branch information
hidetatz authored Dec 31, 2022
2 parents 3080226 + b1cdc0e commit 30c46a5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
2 changes: 2 additions & 0 deletions command/subcommand.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,8 @@ func isColoringSupported(sc kubectl.Subcommand) bool {
kubectl.Plugin,
kubectl.Wait,
kubectl.Run,
kubectl.Ctx,
kubectl.Ns,
}

for _, u := range unsupported {
Expand Down
4 changes: 4 additions & 0 deletions kubectl/subcommand.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@ const (
Plugin
Version
Options
Ctx
Ns
)

var strToSubcommand = map[string]Subcommand{
Expand Down Expand Up @@ -115,6 +117,8 @@ var strToSubcommand = map[string]Subcommand{
"plugin": Plugin,
"version": Version,
"options": Options,
"ctx": Ctx,
"ns": Ns,
}

func InspectSubcommand(command string) (Subcommand, bool) {
Expand Down

0 comments on commit 30c46a5

Please sign in to comment.