This repository has been archived by the owner on Oct 22, 2020. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 265
/
.rubocop.yml
79 lines (62 loc) · 1.95 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
AllCops:
TargetRubyVersion: 2.4
Style/ClassAndModuleChildren:
Description: 'Most modules will use the non-nested syntax'
Enabled: false
Style/RegexpLiteral:
Enabled: false
Metrics/ClassLength:
Description: 'Most modules and payloads are quite large. This is ok.'
Enabled: true
Exclude:
- 'lib/wpxf/modules/**/*'
- 'lib/wpxf/payloads/**/*'
Style/Documentation:
Enabled: true
Description: 'Most modules do not have class documentation.'
Exclude:
- 'lib/wpxf/modules/**/*'
Metrics/LineLength:
Description: 'Modules often pattern match against very long strings when identifying targets.'
Enabled: true
Max: 180
Metrics/MethodLength:
Enabled: true
Description: 'While the style guide suggests 10 lines, exploit definitions often exceed 200 lines.'
Max: 300
Style/WordArray:
Enabled: false
Description: 'Prefer consistent use of []'
Style/RedundantBegin:
Exclude:
- 'lib/wpxf/modules/**/*'
Documentation:
Exclude:
- 'lib/wpxf/modules/**/*'
Style/IndentArray:
Enabled: false
Description: 'A lot of modules use a sensible indentation level that Rubocop does not like.'
Lint/UnusedMethodArgument:
Description: 'A number of classes will contain unused parameters for documentation purposes.'
Exclude:
- 'lib/wpxf/**/*'
Style/ConditionalAssignment:
Enabled: false
Description: 'On long lines, this results in really bad formatting issues.'
Style/IfUnlessModifier:
Enabled: false
Description: 'The modifier does not always increase readability.'
Style/ClassVars:
Enabled: false
Description: 'There are genuine use cases for using class vars.'
Metrics/BlockLength:
Enabled: true
Description: 'Some unit tests are going to be naturally long; no need to flag this up.'
Exclude:
- spec/**/*
Layout/EmptyLinesAroundArguments:
Description: 'Produces false positives when using multi-line strings with spaces.'
Exclude:
- 'lib/wpxf/modules/**/*'
Lint/AmbiguousRegexpLiteral:
Enabled: false