Skip to content

Commit 95b9c42

Browse files
committed
chore: improve CLI help output
1 parent 355532a commit 95b9c42

File tree

12 files changed

+27
-30
lines changed

12 files changed

+27
-30
lines changed

docs/data/cli_help.json

Lines changed: 12 additions & 12 deletions
Large diffs are not rendered by default.

pkg/commands/cache.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ func newCacheCommand() *cacheCommand {
2121

2222
cacheCmd := &cobra.Command{
2323
Use: "cache",
24-
Short: "Cache control and information",
24+
Short: "Cache control and information.",
2525
Args: cobra.NoArgs,
2626
RunE: func(cmd *cobra.Command, _ []string) error {
2727
return cmd.Help()

pkg/commands/config.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ func newConfigCommand(log logutils.Log, info BuildInfo) *configCommand {
4242

4343
configCmd := &cobra.Command{
4444
Use: "config",
45-
Short: "Config file information",
45+
Short: "Configuration file information and verification.",
4646
Args: cobra.NoArgs,
4747
RunE: func(cmd *cobra.Command, _ []string) error {
4848
return cmd.Help()
@@ -52,7 +52,7 @@ func newConfigCommand(log logutils.Log, info BuildInfo) *configCommand {
5252

5353
verifyCommand := &cobra.Command{
5454
Use: "verify",
55-
Short: "Verify configuration against JSON schema",
55+
Short: "Verify configuration against JSON schema.",
5656
Args: cobra.NoArgs,
5757
ValidArgsFunction: cobra.NoFileCompletions,
5858
RunE: c.executeVerify,
@@ -62,7 +62,7 @@ func newConfigCommand(log logutils.Log, info BuildInfo) *configCommand {
6262

6363
pathCommand := &cobra.Command{
6464
Use: "path",
65-
Short: "Print used config path",
65+
Short: "Print used configuration path.",
6666
Args: cobra.NoArgs,
6767
ValidArgsFunction: cobra.NoFileCompletions,
6868
RunE: c.executePath,

pkg/commands/custom.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ func newCustomCommand(logger logutils.Log) *customCommand {
2626

2727
customCmd := &cobra.Command{
2828
Use: "custom",
29-
Short: "Build a version of golangci-lint with custom linters",
29+
Short: "Build a version of golangci-lint with custom linters.",
3030
Args: cobra.NoArgs,
3131
PreRunE: c.preRunE,
3232
RunE: c.runE,

pkg/commands/fmt.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ func newFmtCommand(logger logutils.Log, info BuildInfo) *fmtCommand {
5050

5151
fmtCmd := &cobra.Command{
5252
Use: "fmt",
53-
Short: "Format Go source files",
53+
Short: "Format Go source files.",
5454
RunE: c.execute,
5555
PreRunE: c.preRunE,
5656
PersistentPreRunE: c.persistentPreRunE,

pkg/commands/formatters.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ func newFormattersCommand(logger logutils.Log) *formattersCommand {
4747

4848
formattersCmd := &cobra.Command{
4949
Use: "formatters",
50-
Short: "List current formatters configuration",
50+
Short: "List current formatters configuration.",
5151
Args: cobra.NoArgs,
5252
ValidArgsFunction: cobra.NoFileCompletions,
5353
RunE: c.execute,

pkg/commands/help.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ func newHelpCommand(logger logutils.Log) *helpCommand {
3131

3232
helpCmd := &cobra.Command{
3333
Use: "help",
34-
Short: "Help",
34+
Short: "Display extra help",
3535
Args: cobra.NoArgs,
3636
RunE: func(cmd *cobra.Command, _ []string) error {
3737
return cmd.Help()
@@ -40,7 +40,7 @@ func newHelpCommand(logger logutils.Log) *helpCommand {
4040

4141
lintersCmd := &cobra.Command{
4242
Use: "linters",
43-
Short: "Help about linters",
43+
Short: "Display help for linters.",
4444
Args: cobra.NoArgs,
4545
ValidArgsFunction: cobra.NoFileCompletions,
4646
RunE: c.lintersExecute,
@@ -56,7 +56,7 @@ func newHelpCommand(logger logutils.Log) *helpCommand {
5656

5757
formattersCmd := &cobra.Command{
5858
Use: "formatters",
59-
Short: "Help about formatters",
59+
Short: "Display help for formatters.",
6060
Args: cobra.NoArgs,
6161
ValidArgsFunction: cobra.NoFileCompletions,
6262
RunE: c.formattersExecute,

pkg/commands/linters.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ func newLintersCommand(logger logutils.Log) *lintersCommand {
4747

4848
lintersCmd := &cobra.Command{
4949
Use: "linters",
50-
Short: "List current linters configuration",
50+
Short: "List current linters configuration.",
5151
Args: cobra.NoArgs,
5252
ValidArgsFunction: cobra.NoFileCompletions,
5353
RunE: c.execute,

pkg/commands/migrate.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ func newMigrateCommand(log logutils.Log, info BuildInfo) *migrateCommand {
5151

5252
migrateCmd := &cobra.Command{
5353
Use: "migrate",
54-
Short: "Migrate configuration file from v1 to v2",
54+
Short: "Migrate configuration file from v1 to v2.",
5555
SilenceUsage: true,
5656
SilenceErrors: true,
5757
Args: cobra.NoArgs,

pkg/commands/run.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ func newRunCommand(logger logutils.Log, info BuildInfo) *runCommand {
111111

112112
runCmd := &cobra.Command{
113113
Use: "run",
114-
Short: "Run the linters",
114+
Short: "Lint the code.",
115115
Run: c.execute,
116116
PreRunE: c.preRunE,
117117
PostRun: c.postRun,

0 commit comments

Comments
 (0)