forked from alleyinteractive/es-admin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
phpcs.xml.dist
53 lines (44 loc) · 1.9 KB
/
phpcs.xml.dist
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
<?xml version="1.0"?>
<ruleset name="es-admin">
<description>Sniffs for the coding standards of the ES Admin plugin</description>
<!--
Pass some flags to PHPCS:
p flag: Show progress of the run.
s flag: Show sniff codes in all reports.
-->
<arg value="ps" />
<!-- Strip the filepaths down to the relevant bit. -->
<arg name="basepath" value="./" />
<!-- Check up to 8 files simultaneously. -->
<arg name="parallel" value="8" />
<!-- Only check the PHP files. -->
<arg name="extensions" value="php" />
<!-- Set severity to 1 to see everything that isn't effectively turned off. -->
<arg name="severity" value="1" />
<!-- Check all files in this directory and the directories below it. -->
<file>.</file>
<exclude-pattern>tests/*</exclude-pattern>
<exclude-pattern>vendor/*</exclude-pattern>
<exclude-pattern>node_modules/*</exclude-pattern>
<rule ref="WordPress">
<exclude name="Squiz.Commenting.LongConditionClosingComment.Missing" />
<exclude name="Squiz.PHP.DisallowMultipleAssignments.Found" />
<exclude name="WordPress.Arrays.ArrayDeclarationSpacing.AssociativeKeyFound" />
<exclude name="Generic.Arrays.DisallowShortArraySyntax.Found" />
<exclude name="PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket" />
<exclude name="PEAR.Functions.FunctionCallSignature.CloseBracketLine" />
<exclude name="PEAR.Functions.FunctionCallSignature.MultipleArguments" />
</rule>
<rule ref="WordPress-VIP-Go" />
<rule ref="Generic.PHP.ForbiddenFunctions">
<properties>
<!--
WordPress.com VIP does not propagate wp_cache_set data across datacenters,
largely to avoid attempting to propagate large (>50k) data for batcache.
-->
<property name="forbiddenFunctions" type="array">
<element key="wp_cache_add" value="wp_cache_set"/>
</property>
</properties>
</rule>
</ruleset>