woodpecker/vendor/github.com/golangci/golangci-lint/pkg/config/severity.go
Lukas c28f7cb29f
Add golangci-lint (#502)
Initial part of #435
2021-11-14 21:01:54 +01:00

18 lines
449 B
Go

package config
const severityRuleMinConditionsCount = 1
type Severity struct {
Default string `mapstructure:"default-severity"`
CaseSensitive bool `mapstructure:"case-sensitive"`
Rules []SeverityRule `mapstructure:"rules"`
}
type SeverityRule struct {
BaseRule `mapstructure:",squash"`
Severity string
}
func (s *SeverityRule) Validate() error {
return s.BaseRule.Validate(severityRuleMinConditionsCount)
}