Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
77 lines (70 sloc) 2.1 KB
AllCops:
TargetRubyVersion: 2.6
Exclude:
- 'db/**/*'
- "tmp/**/*"
- "log/**/*"
- 'node_modules/**/*'
# Rails specific
require: rubocop-rails
Rails/OutputSafety:
Enabled: false # This disallows .html_safe
Rails/TimeZone:
Enabled: false # This enforces Time.zone.now
Rails/Date:
Enabled: false # This enforces Time.zone.today
Rails/HasAndBelongsToMany:
Enabled: false # This disallows HABTM.
# Project styling
Style/IfUnlessModifier:
Enabled: false
Style/FormatStringToken:
Enabled: false
Style/DoubleNegation:
Enabled: false
Layout/AlignParameters:
EnforcedStyle: with_fixed_indentation
Layout/AlignArguments:
EnforcedStyle: with_fixed_indentation
Layout/MultilineOperationIndentation:
EnforcedStyle: indented
Layout/MultilineMethodCallIndentation:
EnforcedStyle: indented
Layout/CaseIndentation:
EnforcedStyle: end
IndentOneStep: true
Layout/EndAlignment:
EnforcedStyleAlignWith: variable
Naming/VariableNumber:
Enabled: false
Metrics/BlockLength:
Exclude:
- 'app/admin/**/*'
- 'spec/**/*_spec.rb'
- 'config/**/*'
- 'spec/factories/*'
Lint/ShadowingOuterLocalVariable: # shadowing is a language feature - we should use it where appropriate.
Enabled: false
# Concessions (remove these if possible / appropriate).
Layout/EmptyLinesAroundAccessModifier:
Enabled: false # TODO: Enable this once it stops begin buggy. https://github.com/rubocop-hq/rubocop/issues/7212
Bundler/OrderedGems:
Enabled: false # we have a ton of gems, grouped arbitrarily. Could be tackled later.
Style/FrozenStringLiteralComment:
Enabled: false # forces addition of frozen string literal directive to all files. WTF.
Metrics/LineLength:
Max: 320 # default was 80.
StringLiterals:
Enabled: false
Documentation:
Enabled: false
Metrics/MethodLength:
Max: 20 # default was 10.
Metrics/ClassLength:
Max: 500 # default was 100.
Metrics/AbcSize:
Max: 30 # default is 15.
Style/GuardClause:
Enabled: false # this thing is annoying, and can lead to not-as-readable code.
Style/YodaCondition:
Enabled: false # buggy - sometimes complains about fixed code, and autocorrect doesn't work.
You can’t perform that action at this time.