-
Notifications
You must be signed in to change notification settings - Fork 0
/
.rubocop.yml
141 lines (107 loc) · 2.31 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
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
# Fichier à exclure du scope de Rubocop
# les librairies externes lib/* et vendor/*
# les configurations config/*
# les éléments de la base de donnée db/*
# le bin bin/**/*
AllCops:
Exclude:
- "lib/**/*"
- "vendor/**/*"
- "config/**/*"
- "db/**/*"
- "bin/**/*"
# Règles de mise en forme - LAYOUT
Layout/BeginEndAlignment:
Enabled: true
EnforcedStyleAlignWith: begin
Layout/ClassStructure:
Enabled: true
ExpectedOrder:
- module_inclusion
- constants
- association
- public_attribute_macros
- public_delegate
- macros
- initializer
- public_class_methods
- public_methods
- protected_attribute_macros
- protected_methods
- private_attribute_macros
- private_delegate
- private_methods
Layout/ClosingHeredocIndentation:
Enable: false
Layout/ClosingParenthesisIndentation:
Enable: true
Layout/IndentationStyle:
Enable: true
EnforcedStyle: tabs
Layout/LineLength:
Enable: true
Max: 150
Layout/MultilineAssignmentLayout:
Enable: true
Layout/MultilineHashKeyLineBreaks:
Enable: true
Layout/MultilineMethodArgumentLineBreaks:
Enable: true
# Fin règles de mise en forme - LAYOUT
# Règles de lint - LINT
Lint/AmbiguousAssignment:
Enable: true
Lint/DuplicateBranch:
Enable: true
# Fin règles de lint - LINT
# Règles de métriques - METRICS
Metrics/AbcSize:
Enable: true
Max: 25
Metrics/BlockLength:
Enable: true
Max: 50
CountAsOne:
- array
- hash
Metrics/ClassLength:
Enable: true
Max: 150
CountAsOne:
- array
- hash
Metrics/MethodLength:
Enable: true
Max: 50
CountAsOne:
- array
- hash
Metrics/ModuleLength:
Enable: true
Max: 150
CountAsOne:
- array
- hash
# Fin règles de métriques - METRICS
# Règles de style - STYLE
Style/HashEachMethods:
Enabled: true
Style/HashTransformKeys:
Enabled: true
Style/HashTransformValues:
Enabled: true
Style/IpAddresses:
Enabled: true
Style/TrailingMethodEndStatement:
Enabled: true
Style/TrailingCommaInArguments:
EnforcedStyleForMultiline: no_comma
Style/TrailingCommaInArrayLiteral:
EnforcedStyleForMultiline: no_comma
Style/TrailingCommaInHashLiteral:
EnforcedStyleForMultiline: no_comma
Style/EmptyElse:
EnforcedStyle: both
Style/SymbolArray:
EnforcedStyle: brackets
# Fin règles de style - STYLE