-
Notifications
You must be signed in to change notification settings - Fork 28
/
.phpcs.xml
25 lines (25 loc) · 1.26 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
<?xml version="1.0"?>
<ruleset name="OOUI">
<rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki">
<!-- Disabled because it complains about "missing" documentation where it is inherited -->
<exclude name="MediaWiki.Commenting.FunctionComment.MissingDocumentationProtected" />
<exclude name="MediaWiki.Commenting.FunctionComment.MissingDocumentationPublic" />
<!-- Together with the above, false positives in WikimediaUITheme.php and others -->
<exclude name="MediaWiki.Commenting.PropertyDocumentation.MissingDocumentationProtected" />
<exclude name="MediaWiki.NamingConventions.PrefixedGlobalFunctions.allowedPrefix" />
</rule>
<!-- Allow superglobals in entry points -->
<rule ref="MediaWiki.Usage.SuperGlobalsUsage.SuperGlobals">
<exclude-pattern>*/demos/demos.php</exclude-pattern>
<exclude-pattern>*/demos/widgets.php</exclude-pattern>
</rule>
<!-- Allow global functions in tests -->
<rule ref="MediaWiki.NamingConventions.PrefixedGlobalFunctions.wfPrefix">
<exclude-pattern>*/tests/*.php</exclude-pattern>
</rule>
<file>.</file>
<arg name="encoding" value="UTF-8"/>
<arg name="extensions" value="php"/>
<exclude-pattern type="relative">^build/*</exclude-pattern>
<exclude-pattern type="relative">^demos/(php|vendor)/*</exclude-pattern>
</ruleset>