forked from johncms/johncms
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathphpcs.xml.dist
More file actions
executable file
·51 lines (46 loc) · 1.72 KB
/
phpcs.xml.dist
File metadata and controls
executable file
·51 lines (46 loc) · 1.72 KB
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
<?xml version="1.0"?>
<ruleset name="JohnCMS coding standard">
<description>JohnCMS coding standard</description>
<arg name="colors"/>
<arg name="extensions" value="php"/>
<!-- display progress -->
<arg value="p"/>
<!-- Paths to check -->
<file>config</file>
<file>modules</file>
<file>system/src</file>
<exclude-pattern>/config/autoload/*.local.php</exclude-pattern>
<exclude-pattern>/modules/*/locale/*.lng.php</exclude-pattern>
<exclude-pattern>/modules/*/migrations/*</exclude-pattern>
<exclude-pattern>/system/migrations/*</exclude-pattern>
<exclude-pattern>*\.blade\.php</exclude-pattern>
<!-- inherit rules from: -->
<rule ref="PSR12"/>
<rule ref="PSR1.Files.SideEffects">
<exclude-pattern>modules</exclude-pattern>
</rule>
<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
<rule ref="Squiz.WhiteSpace.SuperfluousWhitespace">
<properties>
<property name="ignoreBlankLines" value="false"/>
</properties>
</rule>
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="240"/>
<property name="absoluteLineLimit" value="320"/>
</properties>
</rule>
<!-- Ban some functions -->
<rule ref="Generic.PHP.ForbiddenFunctions">
<properties>
<property name="forbiddenFunctions" type="array">
<element key="sizeof" value="count"/>
<element key="delete" value="unset"/>
<element key="print" value="echo"/>
<element key="is_null" value="null"/>
<element key="create_function" value="null"/>
</property>
</properties>
</rule>
</ruleset>