forked from markjaquith/wp-help
-
Notifications
You must be signed in to change notification settings - Fork 0
/
phpcs.xml
50 lines (39 loc) · 1.72 KB
/
phpcs.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
<?xml version="1.0"?>
<ruleset name="Slightly relaxed WordPress coding standards">
<description>Based on the WordPress coding standards</description>
<file>.</file>
<!-- Check all PHP files in directory tree by default. -->
<arg name="extensions" value="php"/>
<!-- Show progress and sniff codes in all reports -->
<arg value="ps"/>
<!-- Check up to 20 files simultaneously. -->
<arg name="parallel" value="20"/>
<!-- Whenever possible, cache the scan results and re-use those for unchanged files on the next scan. -->
<arg name="cache"/>
<rule ref="PHPCompatibility"/>
<config name="testVersion" value="7.0-"/>
<rule ref="WordPress-Core">
<exclude name="WordPress.Arrays.MultipleStatementAlignment"/>
<exclude name="Generic.PHP.DisallowShortOpenTag"/>
<exclude name="Generic.PHP.DisallowAlternativePHPTags"/>
<exclude name="WordPress.Files.FileName"/>
<exclude name="WordPress.PHP.YodaConditions"/>
<exclude name="WordPress.PHP.DontExtract"/>
<exclude name="Generic.Formatting.MultipleStatementAlignment"/>
</rule>
<rule ref="PEAR.Functions.FunctionCallSignature">
<severity>0</severity>
</rule>
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket"/>
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket"/>
<rule ref="WordPress-Docs"/>
<!-- Will uncomment this when I start requiring PHP 5.4+ in 2019 -->
<!--<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>-->
<rule ref="Squiz.Commenting.FileComment.Missing">
<exclude-pattern>/templates/*</exclude-pattern>
</rule>
<exclude-pattern>/node_modules/*</exclude-pattern>
<exclude-pattern>/vendor/*</exclude-pattern>
<exclude-pattern>/release/*</exclude-pattern>
<exclude-pattern>/dist/*</exclude-pattern>
</ruleset>