-
Notifications
You must be signed in to change notification settings - Fork 0
/
.rubocop.yml
99 lines (78 loc) · 1.92 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
AllCops:
TargetRubyVersion: 2.5
Exclude:
- bin/**/*
- contrib/**/*
- config/**/*
- db/**/*
- tmp/**/*
- Capfile
- Gemfile
- Rakefile
# Nested module syntax is fine, just be careful with
# scoping, i.e. on include
Style/ClassAndModuleChildren:
Enabled: false
# Old ruby style syntax may still be needed
Style/HashSyntax:
Enabled: true
# Never break line due to length, except in data
# vim: set wrap
Metrics/LineLength:
Max: 1024
# Rails controllers and such
Metrics/MethodLength:
Max: 20
# Use and/or for flow control, but not in boolean assignments
# http://devblog.avdi.org/2010/08/02/using-and-and-or-in-ruby/
Style/AndOr:
Enabled: false
# Use not with .select and flow control
Style/Not:
Enabled: false
# Use { only for single line blocks, but allow block content on its own line to keep line length short
# each { |l|
# l.apply_long_method_name
# }
Style/BlockDelimiters:
Enabled: false
# Do not use lambda
Style/Lambda:
Enabled: false
# Allow TODO instead of requiring TODO:
Style/CommentAnnotation:
Enabled: false
# Do not write 1234 as 1_234
Style/NumericLiterals:
Enabled: false
# Relax for controllers with multiple formats
Metrics/AbcSize:
Max: 40
# Too spammy
Style/Documentation:
Enabled: false
# Will probably be default in ruby 3
Style/FrozenStringLiteralComment:
Enabled: false
# Use raise if you expect to catch the expception
Style/SignalException:
Enabled: false
# False positive for if var = value
Lint/AssignmentInCondition:
Enabled: false
# Too much manual horizontal alignment
Style/AlignHash:
Enabled: false
Style/AlignParameters:
Enabled: false
Style/AlignArray:
Enabled: false
# Vim prefers fixed indent, avoid manual vertical alignment
Style/AlignParameters:
Enabled: true
EnforcedStyle: with_fixed_indentation
Style/MultilineMethodCallIndentation:
EnforcedStyle: indented
# Load order is important
Bundler/OrderedGems:
Enabled: false