Ctrl K
ComunidadGuías…

phpcs.xml

Rama master · réplica de lectura del repositorio original.

Archivo original ↗Preguntar a KiBot
<?xml version="1.0"?>
<ruleset name="StrictPSR12" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:noNamespaceSchemaLocation="vendor/squizlabs/php_codesniffer/phpcs.xsd">
    <description>Strict PSR12 code style standard</description>

    <arg name="basepath" value="."/>
    <arg name="cache" value=".phpcs-cache"/>
    <arg name="colors"/>
    <arg name="extensions" value="php"/>

    <file>src</file>

    <rule ref="PSR12">
        <exclude name="Squiz.WhiteSpace.ControlStructureSpacing.SpacingAfterOpen"/>
        <exclude name="Squiz.WhiteSpace.ControlStructureSpacing.SpacingBeforeClose"/>
        <exclude name="PSR12.Functions.ReturnTypeDeclaration"/>
    </rule>

    <rule ref="Generic.Files.LineLength">
        <exclude name="Generic.Files.LineLength.TooLong"/>
    </rule>

    <rule ref="Generic.PHP.CharacterBeforePHPOpeningTag"/>
    <rule ref="Generic.PHP.DisallowShortOpenTag">
        <exclude name="Generic.PHP.DisallowShortOpenTag.EchoFound"/>
    </rule>
    <!--    <rule ref="Generic.Files.InlineHTML"/>-->
    <rule ref="Generic.PHP.DeprecatedFunctions"/>
    <!--    <rule ref="Generic.PHP.BacktickOperator"/>-->
    <!--    <rule ref="Generic.PHP.DiscourageGoto"/>-->
    <!--    <rule ref="Squiz.PHP.GlobalKeyword"/>-->
    <!--    <rule ref="Generic.PHP.SAPIUsage"/>-->
    <!--    <rule ref="Generic.PHP.ForbiddenFunctions">-->
    <!--        <properties>-->
    <!--            <property name="forbiddenFunctions" type="array">-->
    <!--                <element key="chop" value="rtrim"/>-->
    <!--                <element key="close" value="closedir"/>-->
    <!--                <element key="compact" value="null"/>-->
    <!--                <element key="delete" value="unset"/>-->
    <!--                <element key="doubleval" value="floatval"/>-->
    <!--                <element key="extract" value="null"/>-->
    <!--                <element key="fputs" value="fwrite"/>-->
    <!--                <element key="ini_alter" value="ini_set"/>-->
    <!--                <element key="is_double" value="is_float"/>-->
    <!--                <element key="is_integer" value="is_int"/>-->
    <!--                <element key="is_long" value="is_int"/>-->
    <!--                <element key="is_null" value="null"/>-->
    <!--                <element key="is_real" value="is_float"/>-->
    <!--                <element key="is_writeable" value="is_writable"/>-->
    <!--                <element key="join" value="implode"/>-->
    <!--                <element key="key_exists" value="array_key_exists"/>-->
    <!--                <element key="pos" value="current"/>-->
    <!--                <element key="settype" value="null"/>-->
    <!--                <element key="show_source" value="highlight_file"/>-->
    <!--                <element key="sizeof" value="count"/>-->
    <!--                <element key="strchr" value="strstr"/>-->
    <!--            </property>-->
    <!--        </properties>-->
    <!--    </rule>-->
    <rule ref="Squiz.WhiteSpace.SemicolonSpacing"/>
    <!--    <rule ref="WebimpressCodingStandard.PHP.RedundantSemicolon"/>-->
    <!--    <rule ref="Squiz.PHP.NonExecutableCode"/>-->
    <!--    <rule ref="Squiz.WhiteSpace.LanguageConstructSpacing"/>-->
    <!--    <rule ref="WebimpressCodingStandard.Formatting.RedundantParentheses"/>-->
    <rule ref="Squiz.PHP.LowercasePHPFunctions"/>
    <rule ref="WebimpressCodingStandard.WhiteSpace.BlankLine"/>
    <rule ref="WebimpressCodingStandard.WhiteSpace.BraceBlankLine"/>
    <rule ref="Squiz.Strings.ConcatenationSpacing">
        <properties>
            <property name="spacing" value="1"/>
            <property name="ignoreNewlines" value="true"/>
        </properties>
    </rule>
    <rule ref="WebimpressCodingStandard.Strings.NoConcatenationAtTheEnd"/>
    <rule ref="Generic.Strings.UnnecessaryStringConcat">
        <!-- But multiline is useful for readability -->
        <properties>
            <property name="allowMultiline" value="true"/>
        </properties>
    </rule>
    <!-- The short array syntax MUST be used to define arrays. -->
    <rule ref="Generic.Arrays.DisallowLongArraySyntax"/>
    <!-- All values in multiline arrays must be indented with 4 spaces. -->
    <rule ref="Generic.Arrays.ArrayIndent"/>
    <rule ref="WebimpressCodingStandard.Arrays.TrailingArrayComma"/>
    <rule ref="WebimpressCodingStandard.Arrays.Format"/>
    <!--    <rule ref="SlevomatCodingStandard.PHP.ShortList"/>-->
    <rule ref="WebimpressCodingStandard.WhiteSpace.Namespace"/>
    <!--    &lt;!&ndash; There MAY NOT be a space around a namespace separator. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.WhiteSpace.NamespaceSeparator"/>
    <!--    &lt;!&ndash; Import statements MUST be alphabetically sorted. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.Namespaces.AlphabeticallySortedUses"/>
    <!-- Functions and const keywords MUST be lowercase in import statements. -->
    <rule ref="WebimpressCodingStandard.Namespaces.ConstAndFunctionKeywords"/>
    <!--    &lt;!&ndash; Unused import statements MUST be removed.&ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.Namespaces.UnusedUseStatement"/>
    <!--    &lt;!&ndash; Superfluous leading backslash in import statements MUST be removed. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.Namespaces.UseDoesNotStartWithBackslash"/>
    <!--    &lt;!&ndash; Fancy group import statements MUST NOT be used. &ndash;&gt;-->
    <rule ref="SlevomatCodingStandard.Namespaces.DisallowGroupUse"/>
    <!--    &lt;!&ndash; Each import statement MUST be on its own line. &ndash;&gt;-->
    <rule ref="SlevomatCodingStandard.Namespaces.MultipleUsesPerLine"/>
    <!--    &lt;!&ndash; Import statements must be grouped (classes, functions, constants) and-->
    <!--         MUST be separated by empty lines. &ndash;&gt;-->
    <rule ref="SlevomatCodingStandard.Namespaces.NamespaceSpacing"/>
    <!--    &lt;!&ndash; Import statements aliases for classes, traits, functions and constants-->
    <!--         MUST be useful. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.Namespaces.RedundantAlias"/>
    <!--    &lt;!&ndash; Classes, traits, interfaces, constants and functions MUST be imported. &ndash;&gt;-->
    <!--    <rule ref="WebimpressCodingStandard.PHP.DisallowFqn"/>-->

    <!--    <rule ref="Generic.Classes.DuplicateClassName"/>-->
    <!--    &lt;!&ndash; The file name MUST match the case of the terminating class name. &ndash;&gt;-->
    <!--    <rule ref="Squiz.Classes.ClassFileName"/>-->
    <!--    &lt;!&ndash; PHP 4 style constructors MUST NOT be used. &ndash;&gt;-->
    <rule ref="Generic.NamingConventions.ConstructorName"/>
    <!--    &lt;!&ndash; Abstract classes MUST have a `Abstract` prefix. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.NamingConventions.AbstractClass"/>
    <!--    &lt;!&ndash; Exception classes MUST have a `Exception` suffix. &ndash;&gt;-->
    <!--    <rule ref="WebimpressCodingStandard.NamingConventions.Exception"/>-->
    <!--    &lt;!&ndash; Interface classes MUST have a `Interface` suffix. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.NamingConventions.Interface"/>
    <!--    &lt;!&ndash; Trait classes MUST have a `Trait` suffix. &ndash;&gt;-->
    <!--    <rule ref="WebimpressCodingStandard.NamingConventions.Trait"/>-->
    <!--    &lt;!&ndash; Correct class name casing MUST be used. &ndash;&gt;-->
    <!--    <rule ref="WebimpressCodingStandard.PHP.CorrectClassNameCase"/>-->
    <!--    &lt;!&ndash; For self-reference a class lower-case `self::` MUST be used without-->
    <!--         spaces around the scope resolution operator. &ndash;&gt;-->
    <!--    <rule ref="Squiz.Classes.SelfMemberReference"/>-->
    <!--    &lt;!&ndash; Class name resolution via `::class` MUST be used instead of-->
    <!--         `__CLASS__`, `get_class()`, `get_class($this)`,-->
    <!--         `get_called_class()`, `get_parent_class()` and string reference. &ndash;&gt;-->
    <!--    <rule ref="SlevomatCodingStandard.Classes.ModernClassNameReference"/>-->
    <!--    <rule ref="WebimpressCodingStandard.Formatting.StringClassReference"/>-->
    <!--    &lt;!&ndash; There MAY NOT be any whitespace around the double colon operator. &ndash;&gt;-->
    <!--    <rule ref="WebimpressCodingStandard.Formatting.DoubleColon"/>-->

    <!--    &lt;!&ndash; Traits MUST be sorted alphabetically. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.Classes.AlphabeticallySortedTraits"/>

    <!--    &lt;!&ndash; There MUST be a single empty line between methods in a class. &ndash;&gt;-->
    <rule ref="WebimpressCodingStandard.Methods.LineAfter"/>
    <!-- The pseudo-variable `$this` MUST NOT be called inside a static method
         or function. -->
    <rule ref="Squiz.Scope.StaticThisUsage"/>
    <!-- Returned variables SHOULD be useful and SHOULD NOT be assigned to a value
         and returned on the next line. -->
    <rule ref="SlevomatCodingStandard.Variables.UselessVariable"/>

    <rule ref="WebimpressCodingStandard.WhiteSpace.CommaSpacing"/>
    <rule ref="WebimpressCodingStandard.Formatting.NoSpaceAfterSplat"/>
    <rule ref="WebimpressCodingStandard.Formatting.Reference"/>

    <!-- The question mark MUST be used when the default argument value is null. -->
    <rule ref="SlevomatCodingStandard.TypeHints.NullableTypeForNullDefaultValue"/>

        <!-- The final keyword on methods MUST be omitted in final classes. -->
        <rule ref="Generic.CodeAnalysis.UnnecessaryFinalModifier"/>

        <!-- There SHOULD be one single space after `break` and `continue` structures with
             a numeric argument argument. -->
        <rule ref="WebimpressCodingStandard.ControlStructures.BreakAndContinue"/>
        <!-- Statements MUST NOT be empty, except for catch statements. -->
        <rule ref="Generic.CodeAnalysis.EmptyStatement">
            <!-- But allow empty catch -->
            <exclude name="Generic.CodeAnalysis.EmptyStatement.DetectedCatch"/>
        </rule>

        <!-- The `continue` control structure MUST NOT be used in switch statements,
             `break` SHOULD be used instead. -->
        <rule ref="WebimpressCodingStandard.ControlStructures.ContinueInSwitch"/>

        <!-- All catch blocks MUST be reachable. -->
        <rule ref="SlevomatCodingStandard.Exceptions.DeadCatch"/>

    <rule ref="Squiz.WhiteSpace.OperatorSpacing">
        <properties>
            <property name="ignoreNewlines" value="true"/>
        </properties>
    </rule>
    <!--    &lt;!&ndash; There MUST NOT be any white space around the object operator UNLESS-->
    <!--         multilines are used. &ndash;&gt;-->
    <!--    <rule ref="Squiz.WhiteSpace.LogicalOperatorSpacing"/>-->
    <!--    <rule ref="Squiz.WhiteSpace.ObjectOperatorSpacing">-->
    <!--        <properties>-->
    <!--            <property name="ignoreNewlines" value="true"/>-->
    <!--        </properties>-->
    <!--    </rule>-->
    <!--    &lt;!&ndash; Loose comparison operators SHOULD NOT be used, use strict comparison-->
    <!--         operators instead. &ndash;&gt;-->
    <!--    <rule ref="SlevomatCodingStandard.Operators.DisallowEqualOperators"/>-->
    <!--    &lt;!&ndash; The null coalesce operator MUST be used when possible. &ndash;&gt;-->
    <!--    <rule ref="SlevomatCodingStandard.ControlStructures.RequireNullCoalesceOperator"/>-->
    <!--    &lt;!&ndash; Assignment operators SHOULD be used when possible. &ndash;&gt;-->
    <!--    <rule ref="SlevomatCodingStandard.Operators.RequireCombinedAssignmentOperator"/>-->
    <!-- The `&&` and `||` operators SHOULD be used instead of `and` and `or`. -->
    <rule ref="Squiz.Operators.ValidLogicalOperators"/>

    <!--    &lt;!&ndash; There MUST be one whitespace after a type casting operator. &ndash;&gt;-->
    <!--    <rule ref="Generic.Formatting.SpaceAfterCast"/>-->
    <!--    &lt;!&ndash; There MUST be one whitespace after unary not. &ndash;&gt;-->
    <!--    <rule ref="Generic.Formatting.SpaceAfterNot"/>-->

    <!-- Inherited variables passed via `use` MUST be used in closures. -->
    <rule ref="SlevomatCodingStandard.Functions.UnusedInheritedVariablePassedToClosure"/>

    <!--    <rule ref="PEAR.Commenting.InlineComment"/>-->
    <!--    <rule ref="SlevomatCodingStandard.Commenting.EmptyComment"/>-->
    <!--    <rule ref="Squiz.Commenting.FunctionComment">-->
    <!--        &lt;!&ndash; Allow `@throws` without description &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.EmptyThrows"/>-->
    <!--        &lt;!&ndash; Does not work properly with PHP 7 / short-named types &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.IncorrectParamVarName"/>-->
    <!--        &lt;!&ndash; Does not support collections, i.e. `string[]` &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.IncorrectTypeHint"/>-->
    <!--        &lt;!&ndash; Forces incorrect types &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.InvalidReturn"/>-->
    <!--        &lt;!&ndash; Breaks with compound return types, i.e. `string|null` &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.InvalidReturnNotVoid"/>-->
    <!--        &lt;!&ndash; Breaks when all params are not documented &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.InvalidTypeHint"/>-->
    <!--        &lt;!&ndash; Doc comment is not required for every method &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.Missing"/>-->
    <!--        &lt;!&ndash; Do not require comments for `@param` &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.MissingParamComment"/>-->
    <!--        &lt;!&ndash; Do not require `@param` for all parameters &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.MissingParamTag"/>-->
    <!--        &lt;!&ndash; Do not require `@return` for void methods &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.MissingReturn"/>-->
    <!--        &lt;!&ndash; Comments don't have to be sentences &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.ParamCommentFullStop"/>-->
    <!--        &lt;!&ndash; Comments don't have to be sentences &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.ParamCommentNotCapital"/>-->
    <!--        &lt;!&ndash; Breaks when all params are not documented &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.ParamNameNoMatch"/>-->
    <!--        &lt;!&ndash; Doesn't respect inheritance &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.ScalarTypeHintMissing"/>-->
    <!--        &lt;!&ndash; Throws comments can start without a capital and doesn't need a full stop &ndash;&gt;-->
    <!--        <exclude name="PEAR.Commenting.FunctionComment.ThrowsNoFullStop"/>-->
    <!--        <exclude name="PEAR.Commenting.FunctionComment.ThrowsNotCapital"/>-->
    <!--        &lt;!&ndash; Doesn't work with self as typehint &ndash;&gt;-->
    <!--        <exclude name="Squiz.Commenting.FunctionComment.TypeHintMissing"/>-->
    <!--    </rule>-->

    <!-- DocBlocks and comments SHOULD NOT be used for already typehinted arguments,
         except arrays. -->
    <rule ref="WebimpressCodingStandard.Functions.Param">
        <exclude name="WebimpressCodingStandard.Functions.Param.MissingSpecification"/>
        <exclude name="WebimpressCodingStandard.Functions.Param.RedundantParamDoc"/>
    </rule>
    <rule ref="WebimpressCodingStandard.Functions.ReturnType">
        <exclude name="WebimpressCodingStandard.Functions.ReturnType.ReturnValue"/>
        <exclude name="WebimpressCodingStandard.Functions.ReturnType.RedundantReturnDoc"/>
    </rule>
    <!--        <rule ref="WebimpressCodingStandard.Commenting.TagWithType">-->
    <!-- необходимо исключение для шаблонов -->
    <!--            <exclude name="WebimpressCodingStandard.Commenting.TagWithType.InvalidOrder"/>-->
    <!--        </rule>-->

    <!-- The asterisks in a DocBlock should align, and there should be one
         space between the asterisk and tag. -->
    <rule ref="Squiz.Commenting.DocCommentAlignment">
        <exclude name="Squiz.Commenting.DocCommentAlignment.SpaceAfterStar"/>
    </rule>

    <rule ref="SlevomatCodingStandard.Commenting.DocCommentSpacing">
        <properties>
            <property name="linesCountBeforeFirstContent" value="0"/>
            <property name="linesCountAfterLastContent" value="0"/>
            <property name="linesCountBetweenDescriptionAndAnnotations" value="1"/>
            <property name="linesCountBetweenAnnotationsGroups" value="1"/>
            <property name="annotationsGroups" type="array">
                <element value="
                        @internal,
                        @deprecated
                    "/>
                <element value="
                        @link,
                        @uses,
                        @see,
                        @copyright,
                        @license
                    "/>
                <element value="
                        @ORM\,
                        @ODM\,
                        @PHPCR\,
                        @OA\
                    "/>
                <element value="
                        @param\,
                        @return\,
                        @throws\
                    "/>
            </property>
        </properties>
    </rule>

    <!-- The words _private_, _protected_, _static_, _constructor_, _deconstructor_,
         _Created by_, _getter_ and _setter_, MUST NOT be used in comments. -->
    <rule ref="SlevomatCodingStandard.Commenting.ForbiddenComments">
        <properties>
            <property name="forbiddenCommentPatterns" type="array">
                <element value="~^(?:(?!private|protected|static)\S+ )?(?:con|de)structor\.\z~i"/>
                <element value="~^Created by .+\.\z~i"/>
                <element value="~^(User|Date|Time): \S+\z~i"/>
                <element value="~^\S+ [gs]etter\.\z~i"/>
                <element value="~^Class \S+\z~i"/>
            </property>
        </properties>
    </rule>

    <!-- Heredoc and nowdoc tags MUST be uppercase without spaces. -->
    <rule ref="WebimpressCodingStandard.Formatting.Heredoc"/>

    <rule ref="SlevomatCodingStandard.TypeHints.ReturnTypeHintSpacing">
        <properties>
            <property name="spacesCountBeforeColon" value="0"/>
        </properties>
    </rule>
    <rule ref="Generic.WhiteSpace.ScopeIndent"/>
    <rule ref="PSR2.Methods.FunctionCallSignature.Indent"/>
    <rule ref="PSR2.Methods.FunctionCallSignature.OpeningIndent"/>
    <rule ref="Squiz.WhiteSpace.ScopeClosingBrace.Indent"/>

    <!-- Variable names MUST be declared in camelCase. -->
    <rule ref="WebimpressCodingStandard.NamingConventions.ValidVariableName">
        <exclude-pattern>src/Model/*</exclude-pattern>
    </rule>

    <!-- Property name "$_rateTime" should not be prefixed with an underscore to indicate visibility -->
    <rule ref="PSR2.Classes.PropertyDeclaration.Underscore"/>

    <!-- Visibility must be declared on all constants if your project supports PHP 7.1 or later -->
    <rule ref="PSR12.Properties.ConstantVisibility.NotFound"/>

    <!-- Return type is "self" so return tag must be one of: "self", "static" or "$this" -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.ReturnArray"/>

    <!-- Return type in PHPDoc tag is different than declared type in method declaration: "mixed" and "string" -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.DifferentTagAndDeclaration"/>

    <!-- Unexpected type "string" found in return tag -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.ReturnComplexType"/>

    <!-- Function return type is array nor iterable, but function returns array here -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.ReturnArray"/>
    <!-- Function returns only array, but return type contains not array types: false -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.ReturnArrayOnly"/>
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.ReturnSelf"/>

    <!-- Function returns only new instance of PaymentRouteResult, but return type is not only PaymentRouteResult -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.ReturnNewInstanceOnly"/>

    <!-- Return type contains "mixed" which is not an array type -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.NotArrayType"/>

    <!-- Return type of "getDefaultPaymentRouteResult" function is not void, but function has no return statement -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType.InvalidNoReturn"/>

    <!-- Invalid type "string" for parameter $merchantValidationForm -->
    <rule ref="WebimpressCodingStandard.Functions.Param.ParamDocInvalidType">
    </rule>

    <!-- Parameter $form has not been found in function declaration -->
    <rule ref="WebimpressCodingStandard.Functions.Param"/>

    <!-- String concat is not required here; use a single string instead -->
    <rule ref="Generic.Strings.UnnecessaryStringConcat"/>

    <!-- Function returns only boolean true, but return type is not only true -->
    <rule ref="WebimpressCodingStandard.Functions.ReturnType"/>

    <!-- Arguments with default values must be at the end of the argument list -->
    <rule ref="PEAR.Functions.ValidDefaultValue"/>

    <!-- Closing brace of array declaration must be on a new line -->
    <rule ref="Generic.Arrays.ArrayIndent.CloseBraceNotNewLine"/>

    <!-- Multi-line arrays must have a trailing comma after the last element -->
    <rule ref="WebimpressCodingStandard.Arrays.TrailingArrayComma.MissingTrailingComma"/>

    <!-- String "kartik\grid\Module" contains class reference, use ::class instead -->
    <rule ref="WebimpressCodingStandard.Formatting.StringClassReference"/>

    <!-- A double colon must not be followed by a whitespace -->
    <rule ref="WebimpressCodingStandard.Formatting.DoubleColon"/>

    <!-- Parentheses around expression "self::LIST_TYPE_ACTIVE" are redundant -->
    <rule ref="WebimpressCodingStandard.Formatting.RedundantParentheses"/>

    <!-- There must be exactly 1 space(s) between the closing parenthesis and the colon when declaring a return type for a function -->
    <rule ref="WebimpressCodingStandard.Formatting.ReturnType.SpacesBeforeColon">
        <exclude name="WebimpressCodingStandard.Formatting.ReturnType.SpacesBeforeColon"/>
    </rule>

    <!-- There must be one array element per line -->
    <rule ref="WebimpressCodingStandard.Arrays.Format"/>
    <!-- Unexpected space after reference character -->
    <rule ref="WebimpressCodingStandard.Formatting"/>

    <rule ref="PSR1.Files.SideEffects"/>

    <rule ref="PSR1.Classes.ClassDeclaration.MissingNamespace">
        <exclude-pattern>m\d{6}_\d{6}_.+\.php$</exclude-pattern>
    </rule>
    <!-- Ignore camel caps format for class name of migrations -->
    <rule ref="Squiz.Classes.ValidClassName.NotCamelCaps">
        <exclude-pattern>m\d{6}_\d{6}_.+\.php$</exclude-pattern>
    </rule>
    <!-- Ignore no camel caps format for methods name -->
    <rule ref="PSR1.Methods.CamelCapsMethodName.NotCamelCaps">
        <exclude-pattern>*</exclude-pattern>
    </rule>
    <exclude-pattern>vendor/*</exclude-pattern>
    <exclude-pattern>tests/*</exclude-pattern>

    <rule ref="PSR2.Methods.MethodDeclaration.Underscore">
        <exclude-pattern>*/tests/unit/*</exclude-pattern>
    </rule>

    <rule ref="PSR1.Files.SideEffects.FoundWithSymbols"/>
    <!-- File appears to be minified and cannot be processed -->
    <exclude-pattern>*.js</exclude-pattern>
    <exclude-pattern>*.css</exclude-pattern>
    <exclude-pattern>*.json</exclude-pattern>
    <exclude-pattern>*.json</exclude-pattern>
    <exclude-pattern>/_my/*</exclude-pattern>
    <exclude-pattern>/_design/*</exclude-pattern>
    <exclude-pattern>/_temp/*</exclude-pattern>
    <exclude-pattern>/_vendors/*</exclude-pattern>
    <exclude-pattern>/_vendors/*</exclude-pattern>
    <exclude-pattern>/wep/_vendors/*</exclude-pattern>
</ruleset>