Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 0 additions & 13 deletions cmd/openshift-install/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package main

import (
"context"
"fmt"
"os/exec"
"path/filepath"
"strings"
Expand Down Expand Up @@ -102,18 +101,6 @@ var (
targets = []target{installConfigTarget, manifestTemplatesTarget, manifestsTarget, ignitionConfigsTarget, clusterTarget}
)

// Deprecated: Use 'create' subcommands instead.
func newTargetsCmd() []*cobra.Command {
var cmds []*cobra.Command
for _, t := range targets {
cmd := *t.command
cmd.Short = fmt.Sprintf("DEPRECATED: USE 'create %s' instead.", cmd.Use)
cmd.RunE = runTargetCmd(t.assets...)
cmds = append(cmds, &cmd)
}
return cmds
}

func newCreateCmd() *cobra.Command {
cmd := &cobra.Command{
Use: "create",
Expand Down
8 changes: 0 additions & 8 deletions cmd/openshift-install/destroy.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,6 @@ func newDestroyCmd() *cobra.Command {
return cmd
}

func newLegacyDestroyClusterCmd() *cobra.Command {
return &cobra.Command{
Use: "destroy-cluster",
Short: "DEPRECATED: Use 'destroy cluster' instead.",
RunE: runDestroyCmd,
}
}

func newDestroyClusterCmd() *cobra.Command {
return &cobra.Command{
Use: "cluster",
Expand Down
5 changes: 0 additions & 5 deletions cmd/openshift-install/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,9 @@ var (
func main() {
rootCmd := newRootCmd()

for _, cmd := range newTargetsCmd() {
rootCmd.AddCommand(cmd)
}

for _, subCmd := range []*cobra.Command{
newCreateCmd(),
newDestroyCmd(),
newLegacyDestroyClusterCmd(),
newVersionCmd(),
newGraphCmd(),
} {
Expand Down