-
Notifications
You must be signed in to change notification settings - Fork 2
/
scalastyle-config.xml
63 lines (56 loc) · 3.45 KB
/
scalastyle-config.xml
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
<scalastyle>
<!-- whitespace checks -->
<check class="org.scalastyle.file.FileTabChecker" level="warning"/>
<check class="org.scalastyle.file.WhitespaceEndOfLineChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NoWhitespaceAfterLeftBracketChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NoWhitespaceBeforeLeftBracketChecker" level="warning"/>
<check class="org.scalastyle.scalariform.SpacesAfterPlusChecker" level="warning"/>
<check class="org.scalastyle.scalariform.SpacesBeforePlusChecker" level="warning"/>
<!-- naming checks -->
<check class="org.scalastyle.scalariform.ClassNamesChecker" level="warning"/>
<check class="org.scalastyle.scalariform.MethodNamesChecker" level="warning"/>
<check class="org.scalastyle.scalariform.ObjectNamesChecker" level="warning"/>
<check class="org.scalastyle.scalariform.PackageObjectNamesChecker" level="warning"/>
<!-- size/complexities checks -->
<check class="org.scalastyle.file.FileLengthChecker" level="warning"/>
<check class="org.scalastyle.scalariform.CyclomaticComplexityChecker" level="warning"/>
<check class="org.scalastyle.scalariform.MethodLengthChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NumberOfMethodsInTypeChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NumberOfTypesChecker" level="warning"/>
<check class="org.scalastyle.scalariform.ParameterNumberChecker" level="warning"/>
<check class="org.scalastyle.file.FileLineLengthChecker" level="warning">
<parameters>
<parameter name="maxLineLength">120</parameter>
</parameters>
</check>
<!-- code smells -->
<check class="org.scalastyle.scalariform.CovariantEqualsChecker" level="warning"/>
<check class="org.scalastyle.scalariform.EqualsHashCodeChecker" level="warning"/>
<check class="org.scalastyle.scalariform.IfBraceChecker" level="warning"/>
<check class="org.scalastyle.scalariform.MagicNumberChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NoCloneChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NoFinalizeChecker" level="warning"/>
<check class="org.scalastyle.scalariform.NullChecker" level="warning"/>
<check class="org.scalastyle.scalariform.PublicMethodsHaveTypeChecker" level="warning"/>
<check class="org.scalastyle.scalariform.ReturnChecker" level="warning"/>
<check class="org.scalastyle.scalariform.SimplifyBooleanExpressionChecker" level="warning"/>
<check class="org.scalastyle.scalariform.StructuralTypeChecker" level="warning"/>
<check class="org.scalastyle.scalariform.UppercaseLChecker" level="warning"/>
<check customId="javaconversions" level="error" class="org.scalastyle.scalariform.TokenChecker">
<parameters>
<parameter name="regex">import.*JavaConversions</parameter>
</parameters>
<customMessage>Use JavaConverters instead of JavaConversions</customMessage>
</check>
<check class="org.scalastyle.scalariform.IllegalImportsChecker" level="warning">
<parameters>
<parameter name="illegalImports"><![CDATA[sun._,java.awt._]]></parameter>
</parameters>
</check>
<check class="org.scalastyle.file.RegexChecker" level="warning">
<parameters>
<parameter name="regex"><![CDATA[println]]></parameter>
</parameters>
<customMessage>Remove debug println</customMessage>
</check>
</scalastyle>