-
Notifications
You must be signed in to change notification settings - Fork 7
/
.rubocop.yml
103 lines (75 loc) · 1.63 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
require:
- rubocop-rails
AllCops:
NewCops: enable
TargetRubyVersion: 2.5
Exclude:
- 'db/schema.rb'
- 'db/migrate/*'
- 'script/**/*'
- !ruby/regexp /old_and_unused\.rb$/
- 'log/**/*'
- 'tmp/**/*'
- '**/Gemfile'
- 'vendor/**/*'
Layout/EmptyLinesAroundArguments:
Enabled: false
Layout/LineLength:
Enabled: true
Lint/EmptyClass:
Exclude:
- 'app/models/application.rb' # Empty class for CanCanCan
Metrics/AbcSize:
Enabled: false
Metrics/BlockLength:
Enabled: false
Style/StringConcatenation:
Enabled: false
Metrics/ClassLength:
Max: 140
Exclude:
- 'test/**/*'
Metrics/MethodLength:
Max: 17
Naming/FileName:
Exclude:
- 'Capfile'
# TODO: app/controllers/application_controller.rb : @contest neeeds to be refactorized.
Naming/MemoizedInstanceVariableName:
Enabled: false
Rails:
Enabled: true
Rails/HasAndBelongsToMany:
Exclude:
- 'app/models/role.rb'
Rails/HasManyOrHasOneDependent:
Enabled: false
Rails/HelperInstanceVariable:
Enabled: false
Rails/SaveBang:
Enabled: false
Rails/FilePath:
EnforcedStyle: slashes
Security/YAMLLoad:
Enabled: false
Style/AutoResourceCleanup:
Enabled: true
Style/CollectionMethods:
Enabled: true
Style/Documentation:
Enabled: false
Style/ModuleFunction:
EnforcedStyle: extend_self
Style/OptionHash:
Enabled: true
Style/Send:
Enabled: true
Style/SingleLineBlockParams:
Enabled: true
Style/AccessModifierDeclarations:
EnforcedStyle: inline
Style/StringMethods:
Enabled: true
# TODO: Code in config/initializers/social_media_text.rb needs to be refactored
Style/DocumentDynamicEvalDefinition:
Enabled: false