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

Commit

Permalink
Merge pull request #565 from yiqigao217/kubectl
Browse files Browse the repository at this point in the history
Rename kubectl hns command 'create2' to 'create'
  • Loading branch information
k8s-ci-robot authored Mar 30, 2020
2 parents c19365d + 2120af5 commit 4735d27
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ import (
"github.com/spf13/cobra"
)

var create2Cmd = &cobra.Command{
Use: "create2 -n parent child",
var createCmd = &cobra.Command{
Use: "create -n parent child",
Short: "Creates a subnamespace under the given parent.",
Args: cobra.ExactArgs(1),
Run: func(cmd *cobra.Command, args []string) {
Expand All @@ -40,7 +40,7 @@ var create2Cmd = &cobra.Command{
},
}

func newCreate2Cmd() *cobra.Command {
create2Cmd.Flags().StringP("namespace", "n", "", "The parent namespace for the new self-serve subnamespace")
return create2Cmd
func newCreateCmd() *cobra.Command {
createCmd.Flags().StringP("namespace", "n", "", "The parent namespace for the new self-serve subnamespace")
return createCmd
}
2 changes: 1 addition & 1 deletion incubator/hnc/pkg/kubectl/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func init() {
rootCmd.AddCommand(newSetCmd())
rootCmd.AddCommand(newDescribeCmd())
rootCmd.AddCommand(newTreeCmd())
rootCmd.AddCommand(newCreate2Cmd())
rootCmd.AddCommand(newCreateCmd())
}

func Execute() {
Expand Down

0 comments on commit 4735d27

Please sign in to comment.