jbox-web/redmine_git_hosting

View on GitHub
.rubocop.yml

Summary

Maintainability
Test Coverage
inherit_from: .rubocop_todo.yml

require:
  - rubocop-performance
  - rubocop-rails

Rails:
  Enabled: true

AllCops:
  TargetRubyVersion: 2.5
  TargetRailsVersion: 5.2
  NewCops: enable
  Include:
    - '**/*.ruby'
    - '**/*.rake'
    - '**/*.rb'
    - '**/*.rsb'
    - '**/Rakefile'
    - '**/Gemfile'

Metrics/AbcSize:
  Enabled: false

Metrics/BlockLength:
  Enabled: false

Metrics/ClassLength:
  Enabled: false

Metrics/CyclomaticComplexity:
  Enabled: false

Layout/LineLength:
  Max: 140

Metrics/MethodLength:
  Enabled: false

Metrics/ModuleLength:
  Enabled: false

Metrics/PerceivedComplexity:
  Max: 45

Rails/ApplicationJob:
  Enabled: false

Rails/ApplicationRecord:
  Enabled: false

Lint/AmbiguousOperatorPrecedence:
  Enabled: false

Rails/CreateTableWithTimestamps:
  Enabled: false

Rails/HelperInstanceVariable:
  Enabled: false

Rails/SkipsModelValidations:
  Enabled: false

Performance/ChainArrayAllocation:
  Enabled: true

Style/AutoResourceCleanup:
  Enabled: true

Style/ExpandPathArguments:
  Enabled: true
  Exclude:
    - spec/**/*

Lint/ConstantDefinitionInBlock:
  Enabled: true
  Exclude:
    - spec/**/*

Metrics/ParameterLists:
  Enabled: true
  CountKeywordArgs: false

Style/FrozenStringLiteralComment:
  Enabled: true
  Exclude:
    - '/**/*.rsb'

Style/OptionHash:
  Enabled: true
  SuspiciousParamNames:
    - options
    - api_options
    - opts
    - args
    - params
    - parameters
    - settings

Style/ReturnNil:
  Enabled: true

Style/MethodCallWithArgsParentheses:
  Enabled: true
  AllowParenthesesInMultilineCall: true
  AllowParenthesesInChaining: true
  EnforcedStyle: omit_parentheses

Style/Documentation:
  Enabled: false

Style/HashTransformKeys:
  Enabled: false

Style/HashTransformValues:
  Enabled: false

Naming/VariableNumber:
  Enabled: false

Layout/SpaceBeforeBrackets:
  Enabled: false

Rails/EnvironmentVariableAccess:
  Enabled: true
  AllowReads: true

# Hrack::Server requires the `initialize` method
Style/RedundantInitialize:
  Enabled: false

# Because our unit tests assert that
Rails/RedundantPresenceValidationOnBelongsTo:
  Enabled: false