vol1ura/Sat_9am_5km

View on GitHub
.rubocop.yml

Summary

Maintainability
Test Coverage
require:
  - rubocop-factory_bot
  - rubocop-rails
  - rubocop-rake
  - rubocop-performance
  - rubocop-rspec

# METRICS
Metrics/AbcSize:
  Max: 35
  Exclude:
   - 'db/**/*'
Metrics/CyclomaticComplexity:
  Max: 8
Metrics/PerceivedComplexity:
  Max: 8
Metrics/MethodLength:
  Max: 16
  Exclude:
   - 'db/**/*'
Metrics/ClassLength:
  Max: 150
  Exclude:
    - 'app/models/**/*'
    - 'db/**/*'
Metrics/BlockLength:
  Exclude:
    - 'app/admin/**/*'
    - 'app/views/admin/**/*'
    - 'lib/tasks/**/*'
    - 'spec/**/*'
    - 'db/**/*'

# STYLE
Style/Documentation:
  Enabled: false
Style/FrozenStringLiteralComment:
  Exclude:
    - 'config.ru'
    - 'app/views/**/*.json.jbuilder'
Style/TrailingCommaInHashLiteral:
  EnforcedStyleForMultiline: comma
Style/TrailingCommaInArguments:
  EnforcedStyleForMultiline: consistent_comma
Style/HashSyntax:
  EnforcedShorthandSyntax: consistent
Style/NumericLiterals:
  Enabled: false
Style/FetchEnvVar:
  AllowedVars:
    - 'DEV_TELEGRAM_ID'
    - 'VK_TOKEN'

Naming/VariableNumber:
  CheckSymbols: false

# LAYOUT
Layout/LineLength:
  Max: 124
Layout/BeginEndAlignment:
  EnforcedStyleAlignWith: begin
Layout/MultilineMethodCallIndentation:
  EnforcedStyle: indented

# LINT
Lint/MissingSuper:
  Exclude:
    - 'app/services/**/*'

# RSpec
RSpec/MultipleExpectations:
  Max: 4
RSpec/ExampleLength:
  Max: 10
RSpec/MultipleMemoizedHelpers:
  Max: 10
RSpec/NestedGroups:
  Max: 4

AllCops:
  TargetRubyVersion: 3.2
  Exclude:
    - 'tmp/**/*'
    - 'bin/**/*'
    - 'config/**/*'
    - 'db/schema.rb'
    - 'db/**/*' # TODO: remove this item
  NewCops: enable