-
Notifications
You must be signed in to change notification settings - Fork 1
/
.phpcs.xml.dist
58 lines (46 loc) · 1.81 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
54
55
56
57
58
<?xml version="1.0"?>
<ruleset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="Woo Solo Api Plugin" xsi:noNamespaceSchemaLocation="https://raw.githubusercontent.com/squizlabs/PHP_CodeSniffer/master/phpcs.xsd">
<description>The Coding standard for the Woo Solo Api plugin.</description>
<exclude-pattern>*/node_modules/*</exclude-pattern>
<exclude-pattern>*/vendor/*</exclude-pattern>
<exclude-pattern>*/assets/*</exclude-pattern>
<exclude-pattern>*/tests/*</exclude-pattern>
<exclude-pattern>*/bin/*</exclude-pattern>
<arg value="sp"/>
<arg name="basepath" value="./"/>
<arg name="parallel" value="8"/>
<arg name="extensions" value="php"/>
<file>src</file>
<file>woo-solo-api.php</file>
<!-- Exclude dependency injection compiled container. -->
<exclude-pattern>src/Core/CompiledContainer.php</exclude-pattern>
<!-- Enforce PSR12 ruleset. -->
<rule ref="PSR12"/>
<arg name="tab-width" value="4"/>
<!-- Tabs should represent 4 spaces. -->
<rule ref="Generic.WhiteSpace.ScopeIndent">
<exclude name="Generic.WhiteSpace.DisallowTabIndent.TabsUsed"/>
<properties>
<property name="indent" value="4"/>
<property name="tabIndent" value="true"/>
</properties>
</rule>
<!-- Line length config. -->
<rule ref="Generic.Files.LineLength">
<properties>
<property name="lineLimit" value="175" />
<property name="absoluteLineLimit" value="0" />
</properties>
</rule>
<!-- Check code for cross-version PHP compatibility. -->
<config name="testVersion" value="7.4-"/>
<rule ref="PHPCompatibility"/>
<rule ref="PHPCompatibilityWP">
<include-pattern>*\.(php|inc)$</include-pattern>
</rule>
<!-- Check against minimum WP version. -->
<config name="minimum_supported_wp_version" value="5.9"/>
<rule ref="PSR12.Classes">
<exclude name="PSR12.Classes.OpeningBraceSpace.Found"/>
</rule>
</ruleset>