-
-
Notifications
You must be signed in to change notification settings - Fork 2
/
phpcs.xml
46 lines (38 loc) · 1.64 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
<?xml version="1.0"?>
<ruleset name="custom">
<description>Custom PHPCS Standard, based on Drupal standards.</description>
<file>web/modules/custom</file>
<file>web/themes/custom</file>
<rule ref="Drupal"/>
<rule ref="DrupalPractice"/>
<rule ref="Generic.Debug.ESLint"/>
<rule ref="PHPCompatibility"/>
<rule ref="Generic.PHP.RequireStrictTypes"/>
<arg name="extensions" value="inc,info,install,module,php,profile,test,theme,js,css"/>
<arg name="colors"/>
<arg value="sp"/>
<arg name="parallel" value="75"/>
<!-- Lint code against platform version specified in composer.json key "config.platform.php". -->
<config name="testVersion" value="8.2"/>
<!-- Exclude front-end assets. -->
<exclude-pattern>.*\/node_modules\/.*</exclude-pattern>
<exclude-pattern>*\.min\.*</exclude-pattern>
<!-- Force no empty lines after function opening brace. -->
<rule ref="Squiz.WhiteSpace.FunctionOpeningBraceSpace">
<type>warning</type>
</rule>
<!-- Force no empty lines before control structure closing. -->
<rule ref="Squiz.WhiteSpace.ControlStructureSpacing.SpacingBeforeClose">
<type>warning</type>
</rule>
<!-- Force no empty lines after control structure closing. -->
<rule ref="Squiz.WhiteSpace.ControlStructureSpacing.LineAfterClose">
<type>warning</type>
</rule>
<!-- Allow long array lines in tests. -->
<rule ref="Drupal.Arrays.Array.LongLineDeclaration">
<exclude-pattern>*.Test\.php</exclude-pattern>
<exclude-pattern>*.TestCase\.php</exclude-pattern>
<exclude-pattern>*.test</exclude-pattern>
</rule>
</ruleset>