|
1 | 1 | <?xml version="1.0"?> |
2 | 2 | <ruleset name="tiny-blocks"> |
3 | 3 | <description>Code style for the tiny-blocks library.</description> |
4 | | - <rule ref="PSR12"/> |
| 4 | + |
5 | 5 | <file>src</file> |
6 | 6 | <file>tests</file> |
| 7 | + |
| 8 | + <rule ref="PSR12"/> |
| 9 | + |
| 10 | + <rule ref="Squiz.Arrays.ArrayBracketSpacing"/> |
| 11 | + <rule ref="Squiz.ControlStructures.ControlSignature"/> |
| 12 | + <rule ref="Squiz.ControlStructures.ElseIfDeclaration"/> |
| 13 | + <rule ref="Squiz.Formatting.OperatorBracket"/> |
| 14 | + <rule ref="Squiz.Functions.FunctionDeclarationArgumentSpacing"> |
| 15 | + <properties> |
| 16 | + <property name="equalsSpacing" value="1"/> |
| 17 | + </properties> |
| 18 | + </rule> |
| 19 | + <rule ref="Squiz.Scope.MethodScope"/> |
| 20 | + <rule ref="Squiz.WhiteSpace.ControlStructureSpacing"/> |
| 21 | + <rule ref="Squiz.WhiteSpace.FunctionSpacing"> |
| 22 | + <properties> |
| 23 | + <property name="spacing" value="1"/> |
| 24 | + <property name="spacingBeforeFirst" value="0"/> |
| 25 | + <property name="spacingAfterLast" value="0"/> |
| 26 | + </properties> |
| 27 | + </rule> |
| 28 | + <rule ref="Squiz.WhiteSpace.SuperfluousWhitespace"/> |
| 29 | + |
| 30 | + <rule ref="Generic.Arrays.DisallowLongArraySyntax"/> |
| 31 | + <rule ref="Generic.CodeAnalysis.EmptyStatement"/> |
| 32 | + <rule ref="Generic.ControlStructures.InlineControlStructure"/> |
| 33 | + <rule ref="Generic.Formatting.DisallowMultipleStatements"/> |
| 34 | + <rule ref="Generic.Metrics.CyclomaticComplexity"> |
| 35 | + <properties> |
| 36 | + <property name="complexity" value="10"/> |
| 37 | + <property name="absoluteComplexity" value="20"/> |
| 38 | + </properties> |
| 39 | + </rule> |
| 40 | + <rule ref="Generic.Metrics.NestingLevel"/> |
| 41 | + <rule ref="Generic.NamingConventions.ConstructorName"/> |
| 42 | + <rule ref="Generic.PHP.DeprecatedFunctions"/> |
| 43 | + <rule ref="Generic.PHP.LowerCaseKeyword"/> |
| 44 | + <rule ref="Generic.Strings.UnnecessaryStringConcat"> |
| 45 | + <properties> |
| 46 | + <property name="allowMultiline" value="true"/> |
| 47 | + </properties> |
| 48 | + </rule> |
| 49 | + |
| 50 | + <rule ref="PSR2.Classes.PropertyDeclaration"/> |
| 51 | + <rule ref="PSR2.Files.EndFileNewline"/> |
| 52 | + <rule ref="PSR2.Methods.MethodDeclaration"/> |
| 53 | + |
| 54 | + <rule ref="SlevomatCodingStandard.Classes.ClassStructure"> |
| 55 | + <properties> |
| 56 | + <property name="groups" type="array"> |
| 57 | + <element value="uses"/> |
| 58 | + <element value="public constants"/> |
| 59 | + <element value="protected constants"/> |
| 60 | + <element value="private constants"/> |
| 61 | + <element value="enum cases"/> |
| 62 | + <element value="public properties, public static properties"/> |
| 63 | + <element value="protected properties, protected static properties"/> |
| 64 | + <element value="private properties, private static properties"/> |
| 65 | + <element value="constructor, destructor"/> |
| 66 | + <element value="all public methods, all protected methods, all private methods, static constructors"/> |
| 67 | + <element value="magic methods"/> |
| 68 | + </property> |
| 69 | + </properties> |
| 70 | + </rule> |
| 71 | + <rule ref="SlevomatCodingStandard.Classes.ModernClassNameReference"/> |
| 72 | + <rule ref="SlevomatCodingStandard.Complexity.Cognitive"/> |
| 73 | + <rule ref="SlevomatCodingStandard.ControlStructures.RequireNullCoalesceOperator"/> |
| 74 | + <rule ref="SlevomatCodingStandard.Namespaces.AlphabeticallySortedUses"/> |
| 75 | + <rule ref="SlevomatCodingStandard.Namespaces.ReferenceUsedNamesOnly"/> |
| 76 | + <rule ref="SlevomatCodingStandard.Namespaces.UnusedUses"> |
| 77 | + <properties> |
| 78 | + <property name="searchAnnotations" value="true"/> |
| 79 | + </properties> |
| 80 | + </rule> |
| 81 | + <rule ref="SlevomatCodingStandard.Namespaces.UseFromSameNamespace"/> |
| 82 | + <rule ref="SlevomatCodingStandard.TypeHints.DeclareStrictTypes"> |
| 83 | + <properties> |
| 84 | + <property name="spacesCountAroundEqualsSign" value="0"/> |
| 85 | + </properties> |
| 86 | + </rule> |
| 87 | + <rule ref="SlevomatCodingStandard.TypeHints.ParameterTypeHint"> |
| 88 | + <exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingTraversableTypeHintSpecification"/> |
| 89 | + </rule> |
| 90 | + <rule ref="SlevomatCodingStandard.TypeHints.PropertyTypeHint"> |
| 91 | + <exclude name="SlevomatCodingStandard.TypeHints.PropertyTypeHint.MissingTraversableTypeHintSpecification"/> |
| 92 | + </rule> |
| 93 | + <rule ref="SlevomatCodingStandard.TypeHints.ReturnTypeHint"> |
| 94 | + <exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingTraversableTypeHintSpecification"/> |
| 95 | + </rule> |
| 96 | + <rule ref="SlevomatCodingStandard.Variables.UnusedVariable"/> |
7 | 97 | </ruleset> |
0 commit comments