forked from CESNET/perun
-
Notifications
You must be signed in to change notification settings - Fork 0
/
checkstyle.xml
77 lines (63 loc) · 3.09 KB
/
checkstyle.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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<?xml version="1.0" ?>
<!DOCTYPE module PUBLIC
"-//Puppy Crawl//DTD Check Configuration 1.2//EN"
"http://www.puppycrawl.com/dtds/configuration_1_2.dtd">
<module name="Checker">
<module name="NewlineAtEndOfFile">
<property name="fileExtensions" value="java, xml, pl, properties, php"/>
</module>
<!-- Check for trailing whitespace. -->
<module name="RegexpSingleline">
<property name="fileExtensions" value="java, xml, pl, properties, php"/>
<property name="format" value="\s+$"/>
<property name="message" value="Line has trailing spaces."/>
</module>
<!-- Space cannot be before tab character. -->
<module name="RegexpSingleline">
<property name="fileExtensions" value="java, xml, pl, properties, php"/>
<property name="format" value=" +\t"/>
<property name="message" value="Space before tab."/>
</module>
<module name="RegexpSingleline">
<property name="fileExtensions" value="xml, pl, properties, php"/>
<property name="format" value="^((?!\s*\*)\t* )"/>
<property name="message" value="Indent must use tab characters."/>
</module>
<!-- This applies to java files only -->
<module name="TreeWalker">
<!-- Check if indents are done via tab char.
<module name="RegexpSinglelineJava">
<property name="format" value="^\t* "/>
<property name="message" value="Indent must use tab characters."/>
<property name="ignoreComments" value="true"/>
</module>
-->
<!-- more complex indent check - recursive up to 10 indentation levels -->
<!-- this is compliant with NetBeans and Intellij IDEA IDEs default java formatting styles -->
<module name="Regexp">
<property name="format"
value="^\t{1}[^\t\n]*\n+\t{2,} +|^\t{2}[^\t\n]*\n+(:?\t{0,1}|\t{3,}) +|^\t{3}[^\t\n]*\n+(:?\t{0,2}|\t{4,}) +|^\t{4}[^\t\n]*\n+(:?\t{0,3}|\t{5,}) +|^\t{5}[^\t\n]*\n+(:?\t{0,4}|\t{6,}) +|^\t{6}[^\t\n]*\n+(:?\t{0,5}|\t{7,}) +|^\t{7}[^\t\n]*\n+(:?\t{0,6}|\t{8,}) +|^\t{8}[^\t\n]*\n+(:?\t{0,7}|\t{9,}) +|^\t{9}[^\t\n]*\n+(:?\t{0,8}|\t{10,}) +|^\t{10}[^\t\n]*\n+(:?\t{0,9}|\t{11,}) +"/>
<property name="illegalPattern" value="true"/>
<property name="message" value="Wrong number of tabs before space on next line. Indent must use tab characters."/>
<property name="ignoreComments" value="true"/>
</module>
<module name="RedundantImport"/>
<module name="UnusedImports"/>
<!-- Modifier Checks -->
<!--<module name="ModifierOrder"/>-->
<!--<module name="RedundantModifier"/>-->
<!-- Checks for blocks. You know, those {}'s -->
<!--<module name="LeftCurly"/>-->
<!-- Checks for common coding problems -->
<!-- Disabled until http://sourceforge.net/tracker/?func=detail&aid=2843447&group_id=29721&atid=397078 is fixed-->
<!--<module name="DoubleCheckedLocking"/>-->
<!--<module name="EmptyStatement"/>-->
<!--<module name="EqualsHashCode"/>-->
<!--<module name="IllegalInstantiation"/>-->
<!-- Miscellaneous other checks. -->
<!--<module name="UpperEll"/>-->
<!--<module name="PackageAnnotation"/>-->
<!--<module name="CovariantEquals"/>-->
<!--<module name="ArrayTypeStyle"/>-->
</module>
</module>