Last active
November 1, 2019 15:32
-
-
Save eliot-akira/80f1837be0c1c9c94850ee17257fa336 to your computer and use it in GitHub Desktop.
WordPress code standard with 2-space indent
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<ruleset name="MyStandard" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://raw.githubusercontent.com/squizlabs/PHP_CodeSniffer/master/phpcs.xsd"> | |
<description>WordPress code standard with 2-space indent.</description> | |
<rule ref="WordPress"> | |
<exclude name="Generic.WhiteSpace.DisallowSpaceIndent" /> | |
<exclude name="PEAR.Functions.FunctionCallSignature.Indent"/> | |
<exclude name="WordPress.Arrays.ArrayIndentation"/> | |
<exclude name="WordPress.WhiteSpace.PrecisionAlignment"/> | |
</rule> | |
<rule ref="Generic.WhiteSpace.DisallowTabIndent" /> | |
<rule ref="Generic.WhiteSpace.ScopeIndent"> | |
<properties> | |
<property name="indent" value="2"/> | |
<property name="tabIndent" value="false"/> | |
<property name="ignoreIndentationTokens" type="array"> | |
<element value="T_HEREDOC"/> | |
<element value="T_NOWDOC"/> | |
<element value="T_INLINE_HTML"/> | |
</property> | |
</properties> | |
</rule> | |
<rule ref="PEAR.Functions.FunctionCallSignature.Indent"> | |
<properties> | |
<property name="indent" value="2"/> | |
</properties> | |
</rule> | |
<rule ref="WordPress.Arrays.ArrayIndentation"> | |
<properties> | |
<property name="indent" value="2"/> | |
<property name="tabIndent" value="false"/> | |
</properties> | |
</rule> | |
<rule ref="WordPress.WhiteSpace.PrecisionAlignment"> | |
<properties> | |
<property name="tabWidth" value="2"/> | |
</properties> | |
</rule> | |
</ruleset> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment