Skip to content

Commit ca5b327

Browse files
authored
docs(help): add see also for the help command (#5173)
1 parent 8ee400c commit ca5b327

File tree

4 files changed

+14
-4
lines changed

4 files changed

+14
-4
lines changed

cmd/scw/testdata/test-all-usage-help-usage.golden

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
🎲🎲🎲 EXIT CODE: 0 🎲🎲🎲
22
🟥🟥🟥 STDERR️️ 🟥🟥🟥️
3-
Get help about how the CLI works
3+
Get help about how specific topics inside the CLI work
44

55
USAGE:
66
scw help <command>
@@ -18,4 +18,8 @@ GLOBAL FLAGS:
1818
-o, --output string Output format: json or human, see 'scw help output' for more info (default "human")
1919
-p, --profile string The config profile to use
2020

21+
SEE ALSO:
22+
# Print general help
23+
scw --help
24+
2125
Use "scw help [command] --help" for more information about a command.

cmd/scw/testdata/test-main-usage-usage.golden

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ STORAGE COMMANDS:
7777
UTILITY COMMANDS:
7878
autocomplete Autocomplete related commands
7979
feedback Send feedback to the Scaleway CLI Team!
80-
help Get help about how the CLI works
80+
help Get help about how specific topics inside the CLI work
8181
shell Start shell mode
8282
version Display cli version
8383

docs/commands/help.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<!-- DO NOT EDIT: this file is automatically generated using scw-doc-gen -->
22
# Documentation for `scw help`
3-
Get help about how the CLI works
3+
Get help about how specific topics inside the CLI work
44

55
- [Get help about how date parsing works in the CLI](#get-help-about-how-date-parsing-works-in-the-cli)
66
- [Get help about how the CLI output works](#get-help-about-how-the-cli-output-works)

internal/namespaces/help/custom.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,16 @@ func GetCommands() *core.Commands {
1717

1818
func helpRoot() *core.Command {
1919
return &core.Command{
20-
Short: "Get help about how the CLI works",
20+
Short: "Get help about how specific topics inside the CLI work",
2121
Namespace: "help",
2222
AllowAnonymousClient: true,
2323
Groups: []string{"utility"},
24+
SeeAlsos: []*core.SeeAlso{
25+
{
26+
Short: "Print general help",
27+
Command: "scw --help",
28+
},
29+
},
2430
}
2531
}
2632

0 commit comments

Comments
 (0)