diff --git a/config.toml b/config.toml index 090aa9e..5c963ce 100644 --- a/config.toml +++ b/config.toml @@ -1,6 +1,6 @@ severity = "error" confidence = 1.0 -[rules] + [rules.else] arguments = [] severity = "error" diff --git a/lint/rule.go b/lint/rule.go index f8c51e0..f41381c 100644 --- a/lint/rule.go +++ b/lint/rule.go @@ -51,8 +51,8 @@ type Arguments = []string // RuleConfig is type used for the rule configuration. type RuleConfig struct { - Arguments Arguments `toml:"arguments"` - Severity Severity `toml:"severity"` + Arguments Arguments + Severity Severity } // RulesConfig defines the config for all rules. @@ -60,9 +60,9 @@ type RulesConfig = map[string]RuleConfig // Config defines the config of the linter. type Config struct { - Confidence float64 `toml:"confidence"` - Severity Severity `toml:"severity"` - Rules RulesConfig `toml:"rules"` + Confidence float64 + Severity Severity + Rules RulesConfig } // Rule defines an abstract rule interaface