-
Notifications
You must be signed in to change notification settings - Fork 59
/
Copy pathprpl-ruleset.xml
57 lines (54 loc) · 2.68 KB
/
prpl-ruleset.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
51
52
53
54
55
56
57
<?xml version="1.0"?>
<ruleset name="Product Platform Team">
<!-- This is not a standalone ruleset but an extension of Wikibase's main PHPCS configuration.
It is invoked separately to prevent conflicts between multiple rule sets.
This ruleset is maintained by the PRPL team and applies only to directories owned by them. -->
<rule ref="Generic.PHP.RequireStrictTypes" />
<rule ref="Generic.WhiteSpace.ScopeIndent" />
<rule ref="Generic.Arrays.ArrayIndent" />
<rule ref="PEAR.Functions.FunctionCallSignature.Indent" />
<rule ref="Squiz.Strings.DoubleQuoteUsage">
<exclude name="Squiz.Strings.DoubleQuoteUsage.ContainsVar" />
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.ParameterTypeHint">
<exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingTraversableTypeHintSpecification" />
<exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.UselessAnnotation" />
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.ReturnTypeHint">
<exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingTraversableTypeHintSpecification" />
<exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.UselessAnnotation" />
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.PropertyTypeHint">
<exclude name="SlevomatCodingStandard.TypeHints.PropertyTypeHint.MissingTraversableTypeHintSpecification" />
</rule>
<rule ref="SlevomatCodingStandard.TypeHints.UselessConstantTypeHint" />
<rule ref="SlevomatCodingStandard.Files.TypeNameMatchesFileName">
<properties>
<property name="rootNamespaces" type="array">
<element key="repo/domains/search/src" value="Wikibase\Repo\Domains\Search"/>
<element key="repo/domains/search/tests/phpunit" value="Wikibase\Repo\Tests\Domains\Search"/>
<element key="repo/domains/crud/src" value="Wikibase\Repo\Domains\Crud"/>
<element key="repo/domains/crud/tests/phpunit" value="Wikibase\Repo\Tests\Domains\Crud"/>
<element key="repo/domains/crud/tests/architecture" value="Wikibase\Repo\Tests\Domains\Crud\Architecture"/>
</property>
</properties>
</rule>
<rule ref="SlevomatCodingStandard.Functions.ArrowFunctionDeclaration">
<properties>
<property name="spacesCountAfterKeyword" value="0"/>
</properties>
</rule>
<rule ref="MediaWiki.Classes.FullQualifiedClassName">
<severity>5</severity>
<properties>
<property name="allowMainNamespace" value="false" />
<property name="allowInheritance" value="false" />
<property name="allowFunctions" value="false" />
</properties>
</rule>
<file>repo/domains/crud</file>
<file>repo/domains/search</file>
<arg name="tab-width" value="4" />
<arg name="extensions" value="php" />
<exclude-pattern>node_modules/*</exclude-pattern>
</ruleset>