oauth-xx/oauth2

View on GitHub
.rubocop.yml

Summary

Maintainability
Test Coverage
inherit_from:
  - .rubocop_todo.yml
  - .rubocop_rspec.yml

inherit_gem:
  rubocop-ruby2_2: rubocop.yml

require:
  - 'rubocop-md'
  # Can be added once we reach rubocop-ruby2_3
  #  - 'rubocop-packaging'
  - 'rubocop-performance'
  - 'rubocop-rake'
  - 'rubocop-rspec'

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

Metrics/BlockLength:
  ExcludedMethods:
    - context
    - describe
    - it
    - shared_context
    - shared_examples
    - shared_examples_for
    - namespace
    - draw

Gemspec/RequiredRubyVersion:
  Enabled: false

Metrics/BlockNesting:
  Max: 2

Metrics/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'

RSpec/DescribeClass:
  Exclude:
    - 'spec/examples/*'

RSpec/NestedGroups:
  Enabled: false

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