inherit_gem:
  rubocop-lts: rubocop-lts.yml

inherit_from:
  - .rubocop_rspec.yml
plugins:
  - rubocop-on-rbs
  - rubocop-packaging
# This tells RuboCop to add the exclusions in this file
# to the default exclusions (and those from other inherited files),
# rather than overwriting them.
inherit_mode:
  merge:
    - Exclude

AllCops:
  DisplayCopNames: true # Display the name of the failing cops
  Exclude:
    - 'gemfiles/vendor/**/*'
    - 'vendor/**/*'
    - '**/.irbrc'

Metrics/BlockLength:
  Enabled: false

Gemspec/RequiredRubyVersion:
  Enabled: false

Metrics/BlockNesting:
  Max: 2

Layout/LineLength:
  Enabled: false

Metrics/ParameterLists:
  Max: 4

Layout/AccessModifierIndentation:
  EnforcedStyle: outdent

Layout/DotPosition:
  EnforcedStyle: trailing

Layout/SpaceInsideHashLiteralBraces:
  EnforcedStyle: no_space

Lint/UnusedBlockArgument:
  Exclude:
    - 'spec/**/*.rb'
    - 'gemfiles/vendor/**/*'
    - 'vendor/**/*'
    - '**/.irbrc'

Style/ClassVars:
  Enabled: false

Style/CollectionMethods:
  PreferredMethods:
    map:      'collect'
    reduce:   'inject'
    find:     'detect'
    find_all: 'select'

Style/Documentation:
  Enabled: false

Style/DoubleNegation:
  Enabled: false

Style/EmptyMethod:
  EnforcedStyle: expanded

Style/Encoding:
  Enabled: false

# Does not work with older rubies
#Style/MapToHash:
#  Enabled: false

# Does not work with older rubies
#Style/RedundantBegin:
#  Enabled: false

Style/TrailingCommaInArrayLiteral:
  EnforcedStyleForMultiline: comma

Style/TrailingCommaInHashLiteral:
  EnforcedStyleForMultiline: comma

Gemspec/DependencyVersion:
  Enabled: false
RBS:
  Enabled: true
Layout/IndentationConsistency:
  Exclude: ['*.md']
