-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathphpcs.xml
More file actions
69 lines (58 loc) · 2.07 KB
/
phpcs.xml
File metadata and controls
69 lines (58 loc) · 2.07 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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<?xml version="1.0" ?>
<ruleset name="WordPress Plugin: shibboleth">
<arg value="s"/>
<arg name="extensions" value="php"/>
<file>.</file>
<!-- Strip the filepaths down to the relevant bit. -->
<arg name="basepath" value="./"/>
<!-- Check up to 20 files simultaneously. -->
<arg name="parallel" value="20"/>
<!-- Check for PHP and WordPress cross-version compatibility. -->
<config name="minimum_supported_wp_version" value="4.0" />
<config name="testVersion" value="5.6-"/>
<rule ref="PHPCompatibilityWP"/>
<rule ref="WordPress"/>
<rule ref="WordPress.WP.I18n">
<properties>
<property name="text_domain" type="array">
<element value="shibboleth" />
</property>
</properties>
</rule>
<!-- Code quality. -->
<rule ref="Squiz.PHP.InnerFunctions"/>
<rule ref="Squiz.PHP.LowercasePHPFunctions"/>
<!-- Exclude comment alignment spacing (it does not allow overrides). -->
<rule ref="Squiz.Commenting.FunctionComment">
<exclude name="Squiz.Commenting.FunctionComment.SpacingAfterParamType"/>
<exclude name="Squiz.Commenting.FunctionComment.SpacingAfterParamName"/>
</rule>
<!-- Override statement alignment to use a single space. -->
<rule ref="Generic.Formatting.MultipleStatementAlignment">
<properties>
<property name="maxPadding" value="1" />
</properties>
</rule>
<rule ref="WordPress.Arrays.MultipleStatementAlignment">
<properties>
<property name="maxColumn" value="1"/>
</properties>
</rule>
<!-- Forbidden 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="create_function" value="null"/>
<element key="array_push" value="null"/>
<element key="array_key_exists" value="isset"/>
</property>
</properties>
</rule>
<!-- Exclude the Composer Vendor directory. -->
<exclude-pattern>/vendor/*</exclude-pattern>
<!-- Exclude the Node Modules directory. -->
<exclude-pattern>/node_modules/*</exclude-pattern>
</ruleset>