mirror of
https://github.com/mgechev/revive.git
synced 2025-11-25 22:12:38 +02:00
docs: improve comments for functions; enable godot (#1382)
This commit is contained in:
@@ -127,7 +127,7 @@ func getFormatters() map[string]lint.Formatter {
|
||||
return result
|
||||
}
|
||||
|
||||
// GetLintingRules yields the linting rules that must be applied by the linter
|
||||
// GetLintingRules yields the linting rules that must be applied by the linter.
|
||||
func GetLintingRules(config *lint.Config, extraRules []lint.Rule) ([]lint.Rule, error) {
|
||||
rulesMap := map[string]lint.Rule{}
|
||||
for _, r := range allRules {
|
||||
@@ -229,7 +229,7 @@ func normalizeConfig(config *lint.Config) {
|
||||
|
||||
const defaultConfidence = 0.8
|
||||
|
||||
// GetConfig yields the configuration
|
||||
// GetConfig yields the configuration.
|
||||
func GetConfig(configPath string) (*lint.Config, error) {
|
||||
config := &lint.Config{}
|
||||
switch {
|
||||
@@ -248,7 +248,7 @@ func GetConfig(configPath string) (*lint.Config, error) {
|
||||
return config, nil
|
||||
}
|
||||
|
||||
// GetFormatter yields the formatter for lint failures
|
||||
// GetFormatter yields the formatter for lint failures.
|
||||
func GetFormatter(formatterName string) (lint.Formatter, error) {
|
||||
formatters := getFormatters()
|
||||
if formatterName == "" {
|
||||
|
||||
Reference in New Issue
Block a user