diff --git a/docs/.generated_docs b/docs/.generated_docs index 18aa33495d1..aa1c65e3da2 100644 --- a/docs/.generated_docs +++ b/docs/.generated_docs @@ -326,7 +326,6 @@ docs/user-guide/kubectl/kubectl_plugin.md docs/user-guide/kubectl/kubectl_port-forward.md docs/user-guide/kubectl/kubectl_proxy.md docs/user-guide/kubectl/kubectl_replace.md -docs/user-guide/kubectl/kubectl_rolling-update.md docs/user-guide/kubectl/kubectl_rollout.md docs/user-guide/kubectl/kubectl_rollout_history.md docs/user-guide/kubectl/kubectl_rollout_pause.md diff --git a/docs/user-guide/kubectl/kubectl_rolling-update.md b/docs/user-guide/kubectl/kubectl_rolling-update.md deleted file mode 100644 index b6fd7a0f989..00000000000 --- a/docs/user-guide/kubectl/kubectl_rolling-update.md +++ /dev/null @@ -1,3 +0,0 @@ -This file is autogenerated, but we've stopped checking such files into the -repository to reduce the need for rebases. Please run hack/generate-docs.sh to -populate this file. diff --git a/pkg/kubectl/cmd/rollingupdate.go b/pkg/kubectl/cmd/rollingupdate.go index 833b1eeae98..4792bc0dc67 100644 --- a/pkg/kubectl/cmd/rollingupdate.go +++ b/pkg/kubectl/cmd/rollingupdate.go @@ -81,9 +81,11 @@ func NewCmdRollingUpdate(f cmdutil.Factory, out io.Writer) *cobra.Command { cmd := &cobra.Command{ Use: "rolling-update OLD_CONTROLLER_NAME ([NEW_CONTROLLER_NAME] --image=NEW_CONTAINER_IMAGE | -f NEW_CONTROLLER_SPEC)", DisableFlagsInUseLine: true, - Short: i18n.T("Perform a rolling update of the given ReplicationController"), - Long: rollingUpdateLong, - Example: rollingUpdateExample, + Short: "Perform a rolling update. This command is deprecated, use rollout instead.", + Long: rollingUpdateLong, + Example: rollingUpdateExample, + Deprecated: `use "rollout" instead`, + Hidden: true, Run: func(cmd *cobra.Command, args []string) { err := RunRollingUpdate(f, out, cmd, args, options) cmdutil.CheckErr(err) diff --git a/pkg/kubectl/cmd/templates/templater.go b/pkg/kubectl/cmd/templates/templater.go index 27b76dc42b7..0892f040318 100644 --- a/pkg/kubectl/cmd/templates/templater.go +++ b/pkg/kubectl/cmd/templates/templater.go @@ -145,7 +145,7 @@ func (t *templater) cmdGroupsString(c *cobra.Command) string { for _, cmdGroup := range t.cmdGroups(c, c.Commands()) { cmds := []string{cmdGroup.Message} for _, cmd := range cmdGroup.Commands { - if cmd.Runnable() { + if cmd.IsAvailableCommand() { cmds = append(cmds, " "+rpad(cmd.Name(), cmd.NamePadding())+" "+cmd.Short) } }