dry-types/.rubocop.yml

266 lines
4.0 KiB
YAML
Raw Permalink Normal View History

# This is a config synced from dry-rb/template-gem repo
2019-10-16 09:40:59 +00:00
2019-03-18 10:27:11 +00:00
AllCops:
TargetRubyVersion: 2.7
NewCops: disable
2020-03-08 19:13:52 +00:00
Exclude:
- benchmarks/*.rb
2020-03-08 19:13:52 +00:00
- spec/support/coverage.rb
- spec/support/warnings.rb
2020-09-26 15:19:01 +00:00
- spec/support/rspec_options.rb
2020-03-08 19:13:52 +00:00
- Gemfile.devtools
- "*.gemspec"
2019-03-18 10:27:11 +00:00
2020-06-23 06:33:12 +00:00
Layout/SpaceAroundMethodCallOperator:
Enabled: false
2020-03-10 10:41:34 +00:00
Layout/SpaceInLambdaLiteral:
2020-01-09 08:49:26 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Layout/MultilineMethodCallIndentation:
Enabled: true
EnforcedStyle: indented
2020-01-09 08:49:26 +00:00
2020-06-23 06:33:12 +00:00
Layout/FirstArrayElementIndentation:
2020-03-10 10:41:34 +00:00
EnforcedStyle: consistent
2020-03-10 21:09:59 +00:00
Layout/SpaceInsideHashLiteralBraces:
Enabled: true
EnforcedStyle: no_space
EnforcedStyleForEmptyBraces: no_space
2020-06-23 06:33:12 +00:00
Layout/LineLength:
Max: 100
2020-01-09 08:49:26 +00:00
Exclude:
- "spec/**/*.rb"
2020-01-09 08:49:26 +00:00
Lint/AmbiguousBlockAssociation:
Enabled: true
# because 'expect { foo }.to change { bar }' is fine
Exclude:
- "spec/**/*.rb"
2020-03-10 10:41:34 +00:00
Lint/BooleanSymbol:
2020-01-09 08:49:26 +00:00
Enabled: false
2021-02-26 09:36:33 +00:00
Lint/ConstantDefinitionInBlock:
Exclude:
- "spec/**/*.rb"
2021-02-26 09:36:33 +00:00
2020-06-23 06:33:12 +00:00
Lint/RaiseException:
Enabled: false
Lint/StructNewOverride:
Enabled: false
Lint/SuppressedException:
Exclude:
- "spec/spec_helper.rb"
Lint/LiteralAsCondition:
Exclude:
- "spec/**/*.rb"
2020-03-10 10:41:34 +00:00
Naming/PredicateName:
Enabled: false
Naming/FileName:
2020-01-09 08:49:26 +00:00
Exclude:
2020-03-10 21:09:59 +00:00
- "lib/*-*.rb"
2020-01-09 08:49:26 +00:00
2020-03-10 10:41:34 +00:00
Naming/MethodName:
2020-01-09 08:49:26 +00:00
Enabled: false
Naming/MethodParameterName:
Enabled: false
2020-03-10 10:41:34 +00:00
Naming/MemoizedInstanceVariableName:
2020-01-04 11:10:25 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Metrics/MethodLength:
2019-03-18 10:27:11 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Metrics/ClassLength:
2019-03-18 10:27:11 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Metrics/BlockLength:
2019-04-23 13:41:40 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Metrics/AbcSize:
Max: 25
2019-10-16 08:42:44 +00:00
2020-03-10 10:41:34 +00:00
Metrics/CyclomaticComplexity:
Enabled: true
Max: 12
2019-04-23 13:41:40 +00:00
2020-06-23 06:33:12 +00:00
Style/ExponentialNotation:
Enabled: false
Style/HashEachMethods:
Enabled: false
Style/HashTransformKeys:
Enabled: false
Style/HashTransformValues:
Enabled: false
2020-03-10 10:41:34 +00:00
Style/AccessModifierDeclarations:
2020-01-04 11:10:25 +00:00
Enabled: false
2019-03-18 10:27:11 +00:00
2020-03-10 10:41:34 +00:00
Style/Alias:
Enabled: true
EnforcedStyle: prefer_alias_method
2019-03-18 10:27:11 +00:00
2020-03-10 10:41:34 +00:00
Style/AsciiComments:
2020-02-02 17:13:42 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Style/BlockDelimiters:
2020-02-14 09:48:14 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Style/ClassAndModuleChildren:
2020-01-09 08:49:26 +00:00
Exclude:
- "spec/**/*.rb"
2019-03-18 10:27:11 +00:00
2020-03-10 10:41:34 +00:00
Style/ConditionalAssignment:
2019-03-18 10:27:11 +00:00
Enabled: false
2019-04-23 13:41:40 +00:00
2020-03-10 10:41:34 +00:00
Style/DateTime:
2019-04-23 13:41:40 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Style/Documentation:
2020-01-04 11:10:25 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Style/EachWithObject:
2019-10-16 08:42:44 +00:00
Enabled: false
2020-03-10 10:41:34 +00:00
Style/FormatString:
2019-10-16 08:42:44 +00:00
Enabled: false
2019-11-03 12:43:56 +00:00
Style/FormatStringToken:
Enabled: false
2020-03-10 10:41:34 +00:00
Style/GuardClause:
Enabled: false
2020-01-09 08:49:26 +00:00
2020-03-10 10:41:34 +00:00
Style/IfUnlessModifier:
2019-11-03 12:43:56 +00:00
Enabled: false
2019-12-14 10:47:52 +00:00
2020-06-24 08:56:03 +00:00
Style/Lambda:
2020-06-24 09:04:20 +00:00
Enabled: false
2020-06-24 08:56:03 +00:00
2020-03-10 10:41:34 +00:00
Style/LambdaCall:
2019-12-14 10:47:52 +00:00
Enabled: false
2019-12-14 14:36:12 +00:00
2020-03-10 10:41:34 +00:00
Style/ParallelAssignment:
2019-12-14 14:36:12 +00:00
Enabled: false
2020-01-09 08:49:26 +00:00
Style/RaiseArgs:
Enabled: false
2020-03-10 10:41:34 +00:00
Style/StabbyLambdaParentheses:
Enabled: false
2020-01-09 08:49:26 +00:00
2020-03-10 10:41:34 +00:00
Style/StringLiterals:
2020-01-09 08:49:26 +00:00
Enabled: true
2020-03-10 21:26:56 +00:00
EnforcedStyle: double_quotes
ConsistentQuotesInMultiline: false
Style/StringLiteralsInInterpolation:
Enabled: true
EnforcedStyle: double_quotes
2020-03-10 10:41:34 +00:00
Style/SymbolArray:
Exclude:
- "spec/**/*.rb"
2020-03-10 10:41:34 +00:00
Style/TrailingUnderscoreVariable:
Enabled: false
2020-09-11 07:51:45 +00:00
Style/MultipleComparison:
Enabled: false
Style/Next:
Enabled: false
Style/AccessorGrouping:
Enabled: false
Style/EmptyLiteral:
Enabled: false
Style/Semicolon:
Exclude:
- "spec/**/*.rb"
Style/HashAsLastArrayItem:
Exclude:
- "spec/**/*.rb"
Style/CaseEquality:
Exclude:
- "lib/dry/monads/**/*.rb"
- "lib/dry/struct/**/*.rb"
- "lib/dry/types/**/*.rb"
- "spec/**/*.rb"
Style/ExplicitBlockArgument:
Exclude:
- "lib/dry/types/**/*.rb"
Style/CombinableLoops:
Enabled: false
Style/EmptyElse:
Enabled: false
Style/DoubleNegation:
Enabled: false
Style/MultilineBlockChain:
Enabled: false
Style/NumberedParametersLimit:
Max: 2
Lint/UnusedBlockArgument:
Exclude:
- "spec/**/*.rb"
Lint/Debugger:
Exclude:
- "bin/console"
Lint/BinaryOperatorWithIdenticalOperands:
Exclude:
- "spec/**/*.rb"
Metrics/ParameterLists:
Exclude:
- "spec/**/*.rb"
Lint/EmptyBlock:
Exclude:
- "spec/**/*.rb"
Lint/UselessMethodDefinition:
Exclude:
- "spec/**/*.rb"
Lint/SelfAssignment:
Enabled: false
Lint/EmptyClass:
Enabled: false
Naming/ConstantName:
Exclude:
- "spec/**/*.rb"
Naming/VariableNumber:
Exclude:
- "spec/**/*.rb"
Naming/BinaryOperatorParameterName:
Enabled: false