Add Credo refactor checks and fix double Enum.map
Add 9 enabled + 1 disabled Credo checks from ex_slop README. Fix MapMap finding in ListeningStats.update/1 (single pass). Disable AppendSingleItem (10 pre-existing violations).
This commit is contained in:
+12
-1
@@ -5,6 +5,15 @@
|
||||
plugins: [{ExSlop, []}],
|
||||
checks: %{
|
||||
extra: [
|
||||
{Credo.Check.Warning.ExpensiveEmptyEnumCheck, []},
|
||||
{Credo.Check.Refactor.DoubleBooleanNegation, []},
|
||||
{Credo.Check.Refactor.CondStatements, []},
|
||||
{Credo.Check.Refactor.MapMap, []},
|
||||
{Credo.Check.Refactor.FilterFilter, []},
|
||||
{Credo.Check.Refactor.RejectReject, []},
|
||||
{Credo.Check.Refactor.FilterCount, []},
|
||||
{Credo.Check.Refactor.NegatedConditionsInUnless, []},
|
||||
{Credo.Check.Refactor.UnlessWithElse, []},
|
||||
{Credo.Check.Refactor.Nesting, max_nesting: 3},
|
||||
{Credo.Check.Readability.ModuleDoc,
|
||||
ignore_names: [
|
||||
@@ -32,7 +41,9 @@
|
||||
]},
|
||||
{Credo.Check.Refactor.CyclomaticComplexity, max_complexity: 12}
|
||||
],
|
||||
disabled: []
|
||||
disabled: [
|
||||
{Credo.Check.Refactor.AppendSingleItem, []}
|
||||
]
|
||||
}
|
||||
# files etc.
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user