-
Notifications
You must be signed in to change notification settings - Fork 2
/
.rubocop.yml
91 lines (85 loc) · 2.93 KB
/
.rubocop.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
inherit_from: .rubocop_todo.yml
require:
- rubocop-capybara
- rubocop-factory_bot
- rubocop-rails
- rubocop-rspec
- rubocop-rspec_rails
AllCops:
DefaultFormatter: fuubar
DisplayCopNames: true
EnabledByDefault: true
Exclude: [node_modules/**/*, vendor/**/*, db/schema.rb]
################################################################################
#
# Rules that depart from rubocop defaults
#
################################################################################
Layout/LineLength: { Max: 80, Exclude: ["config/**/*"], AutoCorrect: true }
Layout/MultilineMethodCallIndentation: { EnforcedStyle: indented }
Metrics/BlockLength:
AllowedMethods:
- describe
- configure
Exclude:
- Guardfile
Rails/FilePath: { EnforcedStyle: slashes }
RSpec/ImplicitSubject: { EnforcedStyle: single_statement_only }
RSpec/MessageExpectation:
EnforcedStyle: expect
Exclude: [spec/support/matchers/invoke_matcher.rb]
RSpec/MessageSpies: { EnforcedStyle: receive }
RSpec/MultipleMemoizedHelpers: { AllowSubject: false, Max: 0 }
Style/ArrayFirstLast: { Exclude: [Guardfile] }
Style/ClassAndModuleChildren: { EnforcedStyle: compact }
Style/CommentedKeyword: { Enabled: false }
Style/MethodCallWithArgsParentheses:
AllowedMethods:
- and
- describe
- exec
- exit
- load
- not_to
- p
- puts
- raise
- require
- require_relative
- to
- warn
Exclude:
- db/**/*.rb
Style/MixinUsage: { Exclude: ['bin/**/*'] }
Style/RedundantFetchBlock: { SafeForConstants: true }
Style/StringLiterals: { EnforcedStyle: double_quotes }
Style/StringLiteralsInInterpolation: { EnforcedStyle: double_quotes }
Style/SymbolArray: { EnforcedStyle: brackets }
Style/TopLevelMethodDefinition: { Exclude: ["bin/**/*"] }
Style/TrailingCommaInArguments: { EnforcedStyleForMultiline: comma }
Style/TrailingCommaInArrayLiteral: { EnforcedStyleForMultiline: comma }
Style/TrailingCommaInHashLiteral: { EnforcedStyleForMultiline: comma }
Style/WordArray: { EnforcedStyle: brackets }
################################################################################
#
# Rules we don't want to enable
#
################################################################################
Bundler/GemComment: { Enabled: false }
Bundler/GemVersion: { Enabled: false }
Layout/SingleLineBlockChain: { Enabled: false }
Lint/ConstantResolution: { Enabled: false }
Rails/RedundantPresenceValidationOnBelongsTo: { Enabled: false }
Rails/SchemaComment: { Enabled: false }
RSpec/AlignLeftLetBrace: { Enabled: false }
RSpec/AlignRightLetBrace: { Enabled: false }
RSpec/StubbedMock: { Enabled: false }
Style/ConstantVisibility: { Enabled: false }
Style/Copyright: { Enabled: false }
Style/Documentation: { Enabled: false }
Style/DocumentationMethod: { Enabled: false }
Style/InlineComment: { Enabled: false }
Style/MissingElse: { Enabled: false }
Style/RequireOrder: { Enabled: false }
Style/SafeNavigation: { Enabled: false }
Style/StringHashKeys: { Enabled: false }