-
Notifications
You must be signed in to change notification settings - Fork 0
/
.rubocop.yml
113 lines (107 loc) · 2.91 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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
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/**/*]
################################################################################
#
# Rules that depart from rubocop defaults
#
################################################################################
# https://github.com/rubocop-hq/rubocop/issues/7841
Style/TrailingCommaInBlockArgs: { Enabled: false }
Layout/LineLength:
Max: 80
AutoCorrect: true
Exclude: ['config/**/*']
Layout/TrailingEmptyLines: { Enabled: false }
Metrics/BlockLength:
AllowedMethods:
- describe
Exclude:
- Guardfile
- db/schema.rb
Rails/FilePath: { EnforcedStyle: slashes }
RSpec/MultipleExpectations:
Exclude:
- spec/system/**/*.rb
RSpec/MessageExpectation: { EnforcedStyle: expect }
Style/ArrayFirstLast: { Exclude: [Guardfile] }
Style/CommentedKeyword: { Enabled: false }
Style/MethodCallWithArgsParentheses:
AllowedMethods:
- attr_accessor
- attr_reader
- attr_writer
- belongs_to
- cattr_accessor
- context
- default
- delegate
- describe
- exec
- exit
- fit
- gem
- has_many
- helper_method
- include
- it
- layout
- load
- not_to
- p
- puts
- rails_require
- raise
- require
- require_relative
- ruby
- source
- store_accessor
- to
- validates
- warn
IgnoreMacros: false
Exclude:
- bin/**/*
- 'config.ru'
- 'config/boot.rb'
- 'config/puma.rb'
- 'config/routes.rb'
- db/**/*.rb
- Guardfile
- Gemfile
Style/MixinUsage: { Exclude: ['bin/**/*'] }
Style/NumericLiterals: { Exclude: [db/schema.rb] }
Style/StringLiterals: { EnforcedStyle: double_quotes }
Style/StringLiteralsInInterpolation: { EnforcedStyle: double_quotes }
Style/SymbolArray: { EnforcedStyle: brackets }
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 }
RSpec/AlignLeftLetBrace: { Enabled: false }
RSpec/AlignRightLetBrace: { 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 }