tilde.news/.rubocop.yml

224 lines
4.6 KiB
YAML
Raw Normal View History

# Please do not 'fix' style issues without a compelling, metrics-driven
# argument that a style change will materially improve cod equality.
# https://github.com/lobsters/lobsters/pull/460
2018-03-02 04:30:57 +00:00
# Project setup:
2018-11-24 22:43:43 +00:00
require: ./extras/prohibit_safe_navigation
require: ./extras/prohibit_form_for_and_form_tag
2018-03-02 04:30:57 +00:00
Rails:
Enabled: true
AllCops:
Include:
2018-08-15 14:44:11 +00:00
- '**/*.rb'
2018-03-02 04:30:57 +00:00
- '**/Rakefile'
- '**/config.ru'
2018-08-15 14:44:11 +00:00
- '**/*.rake'
2018-03-02 04:30:57 +00:00
Exclude:
2018-03-19 21:21:52 +00:00
- Gemfile
2018-03-02 04:50:11 +00:00
- 'bin/**/*'
2018-03-02 04:30:57 +00:00
- 'db/**/*'
- 'vendor/**/*'
2018-03-02 04:30:57 +00:00
# Cop configuration:
# Bundler
# Gemspec
# Layout
Layout/AccessModifierIndentation:
EnforcedStyle: outdent
2018-03-19 18:49:26 +00:00
Layout/AlignArray:
Enabled: false
2018-03-18 05:45:43 +00:00
Layout/AlignHash:
Enabled: false
2018-03-02 15:25:26 +00:00
Layout/CaseIndentation:
EnforcedStyle: end
Layout/ElseAlignment:
Enabled: false
Layout/EmptyLineAfterGuardClause:
Enabled: false
2018-03-02 04:50:11 +00:00
Layout/EmptyLinesAroundExceptionHandlingKeywords:
Enabled: false
2018-03-21 20:19:48 +00:00
Layout/EndAlignment:
EnforcedStyleAlignWith: variable
2018-03-18 00:10:04 +00:00
Layout/IndentHash:
EnforcedStyle: consistent
Layout/MultilineMethodCallBraceLayout:
Enabled: false
Layout/MultilineMethodCallIndentation:
Enabled: false
Layout/SpaceAroundOperators:
Enabled: false
Layout/SpaceInsideBlockBraces:
EnforcedStyle: space
SpaceBeforeBlockParameters: false
Layout/SpaceInsideRangeLiteral:
Enabled: false
2018-03-02 04:30:57 +00:00
# Lint
Lint/HandleExceptions:
Enabled: false
2018-03-02 04:30:57 +00:00
# Metrics
Metrics/AbcSize:
Enabled: false
Metrics/BlockLength:
Enabled: false
Metrics/BlockNesting:
Enabled: false
Metrics/ClassLength:
Enabled: false
Metrics/CyclomaticComplexity:
Enabled: false
Metrics/LineLength:
Max: 100
Metrics/MethodLength:
Enabled: false
Metrics/ModuleLength:
Enabled: false
Metrics/ParameterLists:
Enabled: false
Metrics/PerceivedComplexity:
Enabled: false
2018-03-02 04:30:57 +00:00
# Naming
2018-03-19 19:43:20 +00:00
Naming/AccessorMethodName:
Enabled: false
2018-03-21 20:19:48 +00:00
Naming/MemoizedInstanceVariableName:
Enabled: false
2018-03-18 05:49:40 +00:00
Naming/PredicateName:
Enabled: false
2018-03-19 19:46:09 +00:00
# disabled until class vaiables in extras become constants
2018-03-21 20:19:48 +00:00
Naming/UncommunicativeMethodParamName:
Enabled: false
2018-03-19 19:46:09 +00:00
Naming/VariableName:
Enabled: false
2018-03-02 04:30:57 +00:00
# Performance
Performance/Casecmp:
Enabled: false
Performance/RedundantMatch:
Enabled: false
2018-03-02 04:30:57 +00:00
# Rails
2018-03-19 00:30:53 +00:00
Rails/Blank:
Enabled: false
Rails/FilePath:
Enabled: false
2018-03-21 20:19:48 +00:00
Rails/HttpStatus:
Enabled: false
2018-03-19 00:32:55 +00:00
Rails/OutputSafety:
Enabled: false
2018-03-19 00:42:02 +00:00
Rails/Present:
UnlessBlank: false
Rails/SkipsModelValidations:
Enabled: false
2018-03-02 04:30:57 +00:00
# Security
# Style
2018-03-21 20:19:48 +00:00
Style/AndOr:
EnforcedStyle: conditionals
Style/BlockDelimiters:
Enabled: false
Style/BlockComments:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/CommentedKeyword:
Enabled: false
Style/ClassVars:
Enabled: false
Style/ConditionalAssignment:
Enabled: false
2018-03-14 13:01:14 +00:00
# It would be nice to have this on, but I'm not up for writing 66 of these in
# the process of addressing the initial 4,489 cop warnings.
Style/Documentation:
Enabled: false
Exclude: [db/migrate/**/*, spec/**/*, test/**/*]
2018-03-19 21:18:04 +00:00
Style/DoubleNegation:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/EachWithObject:
Enabled: false
2018-03-21 20:19:48 +00:00
Style/ExpandPathArguments:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/FormatString:
Enabled: false
Style/FrozenStringLiteralComment:
EnforcedStyle: never
Style/GuardClause:
Enabled: false
Style/HashSyntax:
EnforcedStyle: no_mixed_keys
2018-03-21 20:19:48 +00:00
Style/IfInsideElse:
Enabled: false
Style/IfUnlessModifier:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/InverseMethods:
Enabled: false
Style/Lambda:
Enabled: false
2018-03-18 00:26:56 +00:00
Style/LineEndConcatenation:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/MethodDefParentheses:
Enabled: false
Style/MultilineBlockChain:
Enabled: false
Style/MultilineTernaryOperator:
Enabled: false
Style/NegatedIf:
EnforcedStyle: postfix
2018-03-19 21:53:47 +00:00
Style/NegatedWhile:
Enabled: false
Style/Next:
Enabled: false
Style/NonNilCheck:
Enabled: false
2018-03-18 05:47:10 +00:00
Style/NumericPredicate:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/ParallelAssignment:
Enabled: false
Style/PercentLiteralDelimiters:
Enabled: false
2018-03-19 21:14:05 +00:00
Style/PerlBackrefs:
Enabled: false
2018-03-19 02:07:20 +00:00
Style/RaiseArgs:
EnforcedStyle: compact
Style/RedundantBegin:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/RedundantParentheses:
Enabled: false
2018-03-02 13:27:49 +00:00
Style/RedundantReturn:
Enabled: false
Style/RedundantSelf:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/RescueModifier:
Enabled: false
Style/RescueStandardError:
EnforcedStyle: implicit
2018-03-18 00:26:56 +00:00
Style/RegexpLiteral:
AllowInnerSlashes: true
Style/SafeNavigation:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/SignalException:
Enabled: false
2018-03-02 05:07:29 +00:00
Style/StringLiterals:
Enabled: false
2018-03-18 06:05:29 +00:00
Style/SymbolArray:
EnforcedStyle: brackets
Style/TrailingCommaInArguments:
Enabled: false
2018-03-21 20:19:48 +00:00
Style/TrailingCommaInArrayLiteral:
EnforcedStyleForMultiline: consistent_comma
Style/TrailingCommaInHashLiteral:
2018-03-14 13:01:14 +00:00
EnforcedStyleForMultiline: consistent_comma
2018-03-19 21:53:47 +00:00
Style/WhileUntilDo:
Enabled: false
Style/WhileUntilModifier:
Enabled: false
Style/WordArray:
Enabled: false
Style/YodaCondition:
Enabled: false
2018-03-19 21:53:47 +00:00
Style/ZeroLengthPredicate:
Enabled: false