Skip to content

Commit

Permalink
cleanup, use deprecated and example fields
Browse files Browse the repository at this point in the history
  • Loading branch information
Richard87 committed Sep 12, 2024
1 parent 0e7ab0c commit 2310792
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 9 deletions.
9 changes: 4 additions & 5 deletions cmd/scale.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,16 @@ package cmd

import (
"github.com/equinor/radix-cli/pkg/flagnames"
"github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

// startCmd represents the start command
var scaleCmd = &cobra.Command{
Use: "scale",
Short: "Scale component replicas",
Long: `Scale component replicas.`,
Use: "scale",
Short: "Scale component replicas",
Long: `Scale component replicas.`,
Deprecated: "Please use 'rx scale component' instead. Will be removed after September 2025",
RunE: func(cmd *cobra.Command, args []string) error {
logrus.Warn("This command is deprecated. Please use 'rx scale component' instead. Will be removed after September 2025")
return scaleComponentCmd.RunE(cmd, args)
},
}
Expand Down
5 changes: 2 additions & 3 deletions cmd/scaleComponent.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,8 @@ var scaleComponentCmd = &cobra.Command{
Short: "Scale component replicas",
Long: `Used for manually scaling up or down replicas of a Radix application component.
Note: Manual scaling will persist across deployments, and will disable autoscaling.
Examples:
`,
Example: `
# Scale up component to 2 replicas
rx scale --application radix-test --environment dev --component component-abc --replicas 2
Expand Down
2 changes: 1 addition & 1 deletion cmd/startComponent.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ var startComponentCmd = &cobra.Command{
Deprecated: Use 'rx scale component --reset' instead
Resets a manully scaled component to resume normal operations again.`,
Deprecated: " Use 'rx scale component --reset' instead. Will be removed after September 2025",
RunE: func(cmd *cobra.Command, args []string) error {
logrus.Warn("This command is deprecated. Please use 'rx scale component --reset' instead. Will be removed after September 2025")
appName, err := getAppNameFromConfigOrFromParameter(cmd, flagnames.Application)
if err != nil {
return err
Expand Down

0 comments on commit 2310792

Please sign in to comment.