Merge pull request #3573 from yashvardhan-kukreja/issue-3466/no-args-fix

fix: remove NoArgs positional arguments validation
This commit is contained in:
Kubernetes Prow Robot
2025-01-23 13:27:20 -08:00
committed by GitHub
8 changed files with 0 additions and 8 deletions

View File

@@ -30,7 +30,6 @@ import (
// NewCommand returns a new cobra.Command for building // NewCommand returns a new cobra.Command for building
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
// TODO(bentheelder): more detailed usage // TODO(bentheelder): more detailed usage
Use: "build", Use: "build",
Short: "Build one of [node-image]", Short: "Build one of [node-image]",

View File

@@ -33,7 +33,6 @@ import (
// NewCommand returns a new cobra.Command for cluster creation // NewCommand returns a new cobra.Command for cluster creation
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
Use: "completion", Use: "completion",
Short: "Output shell completion code for the specified shell (bash, zsh or fish)", Short: "Output shell completion code for the specified shell (bash, zsh or fish)",
Long: longDescription, Long: longDescription,

View File

@@ -30,7 +30,6 @@ import (
// NewCommand returns a new cobra.Command for cluster creation // NewCommand returns a new cobra.Command for cluster creation
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
Use: "create", Use: "create",
Short: "Creates one of [cluster]", Short: "Creates one of [cluster]",
Long: "Creates one of local Kubernetes cluster (cluster)", Long: "Creates one of local Kubernetes cluster (cluster)",

View File

@@ -31,7 +31,6 @@ import (
// NewCommand returns a new cobra.Command for cluster deletion // NewCommand returns a new cobra.Command for cluster deletion
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
// TODO(bentheelder): more detailed usage // TODO(bentheelder): more detailed usage
Use: "delete", Use: "delete",
Short: "Deletes one of [cluster]", Short: "Deletes one of [cluster]",

View File

@@ -31,7 +31,6 @@ import (
// NewCommand returns a new cobra.Command for export // NewCommand returns a new cobra.Command for export
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
// TODO(bentheelder): more detailed usage // TODO(bentheelder): more detailed usage
Use: "export", Use: "export",
Short: "Exports one of [kubeconfig, logs]", Short: "Exports one of [kubeconfig, logs]",

View File

@@ -32,7 +32,6 @@ import (
// NewCommand returns a new cobra.Command for get // NewCommand returns a new cobra.Command for get
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
// TODO(bentheelder): more detailed usage // TODO(bentheelder): more detailed usage
Use: "get", Use: "get",
Short: "Gets one of [clusters, nodes, kubeconfig]", Short: "Gets one of [clusters, nodes, kubeconfig]",

View File

@@ -43,7 +43,6 @@ type flagpole struct {
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
flags := &flagpole{} flags := &flagpole{}
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
Use: "kind", Use: "kind",
Short: "kind is a tool for managing local Kubernetes clusters", Short: "kind is a tool for managing local Kubernetes clusters",
Long: "kind creates and manages local Kubernetes clusters using Docker container 'nodes'", Long: "kind creates and manages local Kubernetes clusters using Docker container 'nodes'",

View File

@@ -71,7 +71,6 @@ var gitCommit = ""
// NewCommand returns a new cobra.Command for version // NewCommand returns a new cobra.Command for version
func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command { func NewCommand(logger log.Logger, streams cmd.IOStreams) *cobra.Command {
cmd := &cobra.Command{ cmd := &cobra.Command{
Args: cobra.NoArgs,
Use: "version", Use: "version",
Short: "Prints the kind CLI version", Short: "Prints the kind CLI version",
Long: "Prints the kind CLI version", Long: "Prints the kind CLI version",