@@ -4,18 +4,9 @@ import "time"
4
4
5
5
// Run encapsulates the config options for running the linter analysis.
6
6
type Run struct {
7
- IsVerbose bool `mapstructure:"verbose"`
8
- Silent bool
9
- CPUProfilePath string
10
- MemProfilePath string
11
- TracePath string
12
- Concurrency int
13
- PrintResourcesUsage bool `mapstructure:"print-resources-usage"`
7
+ Timeout time.Duration `mapstructure:"timeout"`
14
8
15
- Config string // The path to the golangci config file, as specified with the --config argument.
16
- NoConfig bool
17
-
18
- Args []string
9
+ Concurrency int `mapstructure:"concurrency"`
19
10
20
11
Go string `mapstructure:"go"`
21
12
@@ -25,9 +16,6 @@ type Run struct {
25
16
ExitCodeIfIssuesFound int `mapstructure:"issues-exit-code"`
26
17
AnalyzeTests bool `mapstructure:"tests"`
27
18
28
- Timeout time.Duration
29
-
30
- PrintVersion bool
31
19
SkipFiles []string `mapstructure:"skip-files"`
32
20
SkipDirs []string `mapstructure:"skip-dirs"`
33
21
UseDefaultSkipDirs bool `mapstructure:"skip-dirs-use-default"`
@@ -36,4 +24,21 @@ type Run struct {
36
24
AllowSerialRunners bool `mapstructure:"allow-serial-runners"`
37
25
38
26
ShowStats bool `mapstructure:"show-stats"`
27
+
28
+ // --- Flags only section.
29
+
30
+ IsVerbose bool `mapstructure:"verbose"` // Flag only
31
+
32
+ PrintVersion bool // Flag only. (used by the root command)
33
+
34
+ CPUProfilePath string // Flag only.
35
+ MemProfilePath string // Flag only.
36
+ TracePath string // Flag only.
37
+
38
+ PrintResourcesUsage bool `mapstructure:"print-resources-usage"` // Flag only. // TODO(ldez) need to be enforced.
39
+
40
+ Config string // Flag only. The path to the golangci config file, as specified with the --config argument.
41
+ NoConfig bool // Flag only.
42
+
43
+ Args []string // Flag only. // TODO(ldez) identify the real need and usage.
39
44
}
0 commit comments