-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Closed
Description
I was confused by this section of the --help
text. I wondered why concurrency was defaulting to 4, instead of using runtime.NumCPU()
to scale the number of workers to the user's actual number of cores.
Flags:
-j, --concurrency int Concurrency (default 4)
Apparently, you are doing this 😀👍
rootCmd.PersistentFlags().IntVarP(&e.cfg.Run.Concurrency, "concurrency", "j", runtime.NumCPU(), "Concurrency")
https://github.com/golangci/golangci-lint/blob/master/pkg/commands/root.go#L64
I think the --help
text should be updated to Concurrency (default NumCPU)
or similar. Go programmers will recognize NumCPU
as runtime.NumCPU()
.
Metadata
Metadata
Assignees
Labels
No labels