Skip to content

Commit e89f2a7

Browse files
authored
[polish] Ensure all helptext is consistent (#1716)
## Summary In short, command help is capitalized, flag help is not. ## How was it tested? CICD
1 parent 560627a commit e89f2a7

File tree

6 files changed

+14
-15
lines changed

6 files changed

+14
-15
lines changed

internal/boxcli/auth.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ func loginCmd() *cobra.Command {
5757
func logoutCmd() *cobra.Command {
5858
cmd := &cobra.Command{
5959
Use: "logout",
60-
Short: "logout from devbox",
60+
Short: "Logout from devbox",
6161
Args: cobra.ExactArgs(0),
6262
RunE: func(cmd *cobra.Command, args []string) error {
6363
c, err := auth.NewClient(build.Issuer(), build.ClientID(), scopes)

internal/boxcli/run.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ func runCmd() *cobra.Command {
4747
flags.envFlag.register(command)
4848
flags.config.register(command)
4949
command.Flags().BoolVar(
50-
&flags.pure, "pure", false, "If this flag is specified, devbox runs the script in an isolated environment inheriting almost no variables from the current environment. A few variables, in particular HOME, USER and DISPLAY, are retained.")
50+
&flags.pure, "pure", false, "if this flag is specified, devbox runs the script in an isolated environment inheriting almost no variables from the current environment. A few variables, in particular HOME, USER and DISPLAY, are retained.")
5151
command.Flags().BoolVarP(
52-
&flags.listScripts, "list", "l", false, "List all scripts defined in devbox.json")
52+
&flags.listScripts, "list", "l", false, "list all scripts defined in devbox.json")
5353

5454
command.ValidArgs = listScripts(command, flags)
5555

internal/boxcli/services.go

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,12 @@ func (flags *serviceUpFlags) register(cmd *cobra.Command) {
3434
"compose-file.yaml|yml. Default is directory containing devbox.json",
3535
)
3636
cmd.Flags().BoolVarP(
37-
&flags.background, "background", "b", false, "Run service in background")
37+
&flags.background, "background", "b", false, "run service in background")
3838
}
3939

4040
func (flags *serviceStopFlags) register(cmd *cobra.Command) {
4141
cmd.Flags().BoolVar(
42-
&flags.allProjects, "all-projects", false, "Stop all running services across all your projects.\nThis flag cannot be used simultaneously with the [services] argument")
42+
&flags.allProjects, "all-projects", false, "stop all running services across all your projects.\nThis flag cannot be used simultaneously with the [services] argument")
4343
}
4444

4545
func servicesCmd(persistentPreRunE ...cobraFunc) *cobra.Command {
@@ -86,9 +86,8 @@ func servicesCmd(persistentPreRunE ...cobraFunc) *cobra.Command {
8686
stopCommand := &cobra.Command{
8787
Use: "stop [service]...",
8888
Aliases: []string{"down"},
89-
Short: `Stop one or more services in the current project. If no service is specified,
90-
stops all services in the current project.`,
91-
Long: `Stop one or more services in the current project. If no service is specified, stops all services in the current project. \nIf the --all-projects flag is specified, stops all running services across all your projects. This flag cannot be used with [service] arguments.`,
89+
Short: `Stop one or more services in the current project. If no service is specified, stops all services in the current project.`,
90+
Long: `Stop one or more services in the current project. If no service is specified, stops all services in the current project. \nIf the --all-projects flag is specified, stops all running services across all your projects. This flag cannot be used with [service] arguments.`,
9291
RunE: func(cmd *cobra.Command, args []string) error {
9392
return stopServices(cmd, args, flags, serviceStopFlags)
9493
},
@@ -116,7 +115,7 @@ func servicesCmd(persistentPreRunE ...cobraFunc) *cobra.Command {
116115
&flags.runInCurrentShell,
117116
"run-in-current-shell",
118117
false,
119-
"Run the command in the current shell instead of a new shell",
118+
"run the command in the current shell instead of a new shell",
120119
)
121120
servicesCommand.Flag("run-in-current-shell").Hidden = true
122121
serviceUpFlags.register(upCommand)

internal/boxcli/shell.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ func shellCmd() *cobra.Command {
4040
command.Flags().BoolVar(
4141
&flags.printEnv, "print-env", false, "print script to setup shell environment")
4242
command.Flags().BoolVar(
43-
&flags.pure, "pure", false, "If this flag is specified, devbox creates an isolated shell inheriting almost no variables from the current environment. A few variables, in particular HOME, USER and DISPLAY, are retained.")
43+
&flags.pure, "pure", false, "if this flag is specified, devbox creates an isolated shell inheriting almost no variables from the current environment. A few variables, in particular HOME, USER and DISPLAY, are retained.")
4444

4545
flags.config.register(command)
4646
flags.envFlag.register(command)

internal/boxcli/shellenv.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,15 +49,15 @@ func shellEnvCmd(recomputeEnvIfNeeded *bool) *cobra.Command {
4949
&flags.install, "install", false, "install packages before exporting shell environment")
5050

5151
command.Flags().BoolVar(
52-
&flags.pure, "pure", false, "If this flag is specified, devbox creates an isolated environment inheriting almost no variables from the current environment. A few variables, in particular HOME, USER and DISPLAY, are retained.")
52+
&flags.pure, "pure", false, "if this flag is specified, devbox creates an isolated environment inheriting almost no variables from the current environment. A few variables, in particular HOME, USER and DISPLAY, are retained.")
5353
command.Flags().BoolVar(
5454
&flags.preservePathStack, "preserve-path-stack", false,
55-
"Preserves existing PATH order if this project's environment is already in PATH. "+
55+
"preserves existing PATH order if this project's environment is already in PATH. "+
5656
"Useful if you want to avoid overshadowing another devbox project that is already active")
5757
_ = command.Flags().MarkHidden("preserve-path-stack")
5858
command.Flags().BoolVar(
5959
&flags.noRefreshAlias, "no-refresh-alias", false,
60-
"By default, devbox will add refresh alias to the environment"+
60+
"by default, devbox will add refresh alias to the environment"+
6161
"Use this flag to disable this behavior.")
6262
_ = command.Flags().MarkHidden("no-refresh-alias")
6363

internal/boxcli/update.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,14 +40,14 @@ func updateCmd() *cobra.Command {
4040
&flags.sync,
4141
"sync-lock",
4242
false,
43-
"Sync all devbox.lock dependencies in multiple projects. "+
43+
"sync all devbox.lock dependencies in multiple projects. "+
4444
"Dependencies will sync to the latest local version.",
4545
)
4646
command.Flags().BoolVar(
4747
&flags.allProjects,
4848
"all-projects",
4949
false,
50-
"Update all projects in the working directory, recursively.",
50+
"update all projects in the working directory, recursively.",
5151
)
5252
return command
5353
}

0 commit comments

Comments
 (0)