Skip to content

Commit e2bd681

Browse files
committed
cleanup
1 parent 38992fa commit e2bd681

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

cmd/src/abc.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"github.com/urfave/cli/v3"
88
)
99

10-
var abcCommand = clicompat.WithLegacyHelp(&cli.Command{
10+
var abcCommand = &cli.Command{
1111
Name: "abc",
1212
Usage: "manages agentic batch changes",
1313
UsageText: `'src abc' is a tool that manages agentic batch changes.
@@ -17,14 +17,14 @@ Usage:
1717
src abc command [command options]
1818
1919
The commands are:`,
20+
OnUsageError: clicompat.OnUsageError,
2021
Description: `Use "src abc [command] -h" for more information about a command.`,
2122
HideHelpCommand: true,
2223
HideVersion: true,
2324
Commands: []*cli.Command{
2425
abcVariablesCommand,
2526
},
26-
Action: func(ctx context.Context, c *cli.Command) error {
27-
cli.HelpPrinter(c.Root().Writer, c.CustomRootCommandHelpTemplate, c)
28-
return nil
27+
Action: func(_ context.Context, c *cli.Command) error {
28+
return cli.ShowSubcommandHelp(c)
2929
},
30-
})
30+
}

cmd/src/abc_variables.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"github.com/urfave/cli/v3"
88
)
99

10-
var abcVariablesCommand = clicompat.WithLegacyHelp(&cli.Command{
10+
var abcVariablesCommand = &cli.Command{
1111
Name: "variables",
1212
Usage: "manage workflow instance variables",
1313
UsageText: `'src abc variables' is a tool that manages workflow instance variables on agentic batch changes.
@@ -17,15 +17,15 @@ Usage:
1717
src abc variables command [command options]
1818
1919
The commands are:`,
20+
OnUsageError: clicompat.OnUsageError,
2021
Description: `Use "src abc variables [command] -h" for more information about a command.`,
2122
HideHelpCommand: true,
2223
HideVersion: true,
2324
Commands: []*cli.Command{
2425
abcVariablesSetCommand,
2526
abcVariablesDeleteCommand,
2627
},
27-
Action: func(ctx context.Context, c *cli.Command) error {
28-
cli.HelpPrinter(c.Root().Writer, c.CustomRootCommandHelpTemplate, c)
29-
return nil
28+
Action: func(_ context.Context, c *cli.Command) error {
29+
return cli.ShowSubcommandHelp(c)
3030
},
31-
})
31+
}

0 commit comments

Comments
 (0)