Skip to content

Commit d7772f5

Browse files
committed
Using ExcludeRulesProcessor
Signed-off-by: Maciej "Iwan" Iwanowski <[email protected]>
1 parent 0513849 commit d7772f5

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

pkg/lint/runner.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,12 @@ func NewRunner(cfg *config.Config, log logutils.Log, goenv *goutil.Env,
7070
Linters: r.Linters,
7171
})
7272
}
73+
var excludeRulesProcessor processors.Processor
74+
if cfg.Issues.ExcludeCaseSensitive {
75+
excludeRulesProcessor = processors.NewExcludeRulesCaseSensitive(excludeRules, lineCache, log.Child("exclude_rules"))
76+
} else {
77+
excludeRulesProcessor = processors.NewExcludeRules(excludeRules, lineCache, log.Child("exclude_rules"))
78+
}
7379

7480
return &Runner{
7581
Processors: []processors.Processor{
@@ -89,7 +95,7 @@ func NewRunner(cfg *config.Config, log logutils.Log, goenv *goutil.Env,
8995
processors.NewIdentifierMarker(),
9096

9197
excludeProcessor,
92-
processors.NewExcludeRules(excludeRules, lineCache, log.Child("exclude_rules")),
98+
excludeRulesProcessor,
9399
processors.NewNolint(log.Child("nolint"), dbManager),
94100

95101
processors.NewUniqByLine(cfg),

0 commit comments

Comments
 (0)