annotate vendor/drupal/coder/phpcs.xml.dist @ 19:fa3358dc1485 tip

Add ndrum files
author Chris Cannam
date Wed, 28 Aug 2019 13:14:47 +0100
parents 129ea1e6d783
children
rev   line source
Chris@0 1 <?xml version="1.0"?>
Chris@0 2 <ruleset name="drupal_coder">
Chris@0 3 <description>The coding standard for coder_sniffer.</description>
Chris@0 4
Chris@0 5 <file>coder_sniffer</file>
Chris@0 6
Chris@0 7 <exclude-pattern>*/Test/*</exclude-pattern>
Chris@0 8
Chris@17 9 <!-- The following comes from the 2.9 PHPCS ruleset.xml { -->
Chris@17 10
Chris@17 11 <!-- Include the whole PEAR standard -->
Chris@17 12 <rule ref="PEAR"/>
Chris@17 13
Chris@17 14 <!-- Include some sniffs from other standards that don't conflict with PEAR -->
Chris@17 15 <rule ref="Squiz.Arrays.ArrayBracketSpacing" />
Chris@17 16 <rule ref="Squiz.Arrays.ArrayDeclaration" />
Chris@17 17 <rule ref="Squiz.Commenting.ClosingDeclarationComment" />
Chris@17 18 <rule ref="Squiz.ControlStructures.ElseIfDeclaration" />
Chris@17 19 <rule ref="Squiz.Commenting.BlockComment" />
Chris@17 20 <rule ref="Squiz.Commenting.DocCommentAlignment" />
Chris@17 21 <rule ref="Squiz.Commenting.EmptyCatchComment" />
Chris@17 22 <rule ref="Squiz.Commenting.InlineComment" />
Chris@17 23 <rule ref="Squiz.Commenting.LongConditionClosingComment" />
Chris@17 24 <rule ref="Squiz.Commenting.PostStatementComment" />
Chris@17 25 <rule ref="Squiz.Formatting.OperatorBracket" />
Chris@17 26 <rule ref="Squiz.Operators.ComparisonOperatorUsage" />
Chris@17 27 <rule ref="Squiz.PHP.DisallowInlineIf" />
Chris@17 28 <rule ref="Squiz.Strings.ConcatenationSpacing" />
Chris@17 29 <rule ref="Squiz.WhiteSpace.ControlStructureSpacing" />
Chris@17 30 <rule ref="Squiz.WhiteSpace.FunctionClosingBraceSpace" />
Chris@17 31 <rule ref="Squiz.WhiteSpace.FunctionSpacing" />
Chris@17 32 <rule ref="Squiz.WhiteSpace.OperatorSpacing" />
Chris@17 33 <rule ref="Squiz.WhiteSpace.SuperfluousWhitespace" />
Chris@17 34 <rule ref="Generic.Commenting.Todo"/>
Chris@17 35 <rule ref="Generic.ControlStructures.InlineControlStructure"/>
Chris@17 36 <rule ref="Generic.Formatting.DisallowMultipleStatements"/>
Chris@17 37 <rule ref="Generic.Formatting.SpaceAfterCast"/>
Chris@17 38 <rule ref="Generic.NamingConventions.ConstructorName"/>
Chris@17 39 <rule ref="Generic.PHP.DeprecatedFunctions"/>
Chris@17 40 <rule ref="Generic.PHP.LowerCaseKeyword"/>
Chris@17 41 <rule ref="Generic.Strings.UnnecessaryStringConcat"/>
Chris@17 42 <rule ref="PSR2.Files.EndFileNewline"/>
Chris@17 43 <rule ref="Zend.Files.ClosingTag"/>
Chris@17 44
Chris@17 45 <!-- Only one argument per line in multi-line function calls -->
Chris@17 46 <rule ref="PEAR.Functions.FunctionCallSignature">
Chris@17 47 <properties>
Chris@17 48 <property name="allowMultipleArguments" value="false"/>
Chris@17 49 </properties>
Chris@17 50 </rule>
Chris@17 51
Chris@17 52 <!-- Have 12 chars padding maximum and always show as errors -->
Chris@17 53 <rule ref="Generic.Formatting.MultipleStatementAlignment">
Chris@17 54 <properties>
Chris@17 55 <property name="maxPadding" value="12"/>
Chris@17 56 <property name="error" value="true"/>
Chris@17 57 </properties>
Chris@17 58 </rule>
Chris@17 59
Chris@17 60 <!-- } End of original PHPCS ruleset.xml -->
Chris@0 61
Chris@0 62 <!-- The following sniffs are disabled because we don't want them -->
Chris@0 63 <rule ref="PEAR.Commenting.FileComment">
Chris@0 64 <exclude name="PEAR.Commenting.FileComment.MissingAuthorTag"/>
Chris@0 65 <exclude name="PEAR.Commenting.FileComment.MissingLicenseTag"/>
Chris@0 66 <exclude name="PEAR.Commenting.FileComment.MissingVersion"/>
Chris@0 67 </rule>
Chris@0 68 <rule ref="PEAR.Commenting.ClassComment">
Chris@0 69 <exclude name="PEAR.Commenting.ClassComment.CategoryTagOrder"/>
Chris@0 70 <exclude name="PEAR.Commenting.ClassComment.MissingAuthorTag"/>
Chris@0 71 <exclude name="PEAR.Commenting.ClassComment.MissingLicenseTag"/>
Chris@0 72 </rule>
Chris@0 73 <rule ref="PEAR.NamingConventions.ValidFunctionName">
Chris@0 74 <exclude name="PEAR.NamingConventions.ValidFunctionName.PrivateNoUnderscore"/>
Chris@0 75 </rule>
Chris@0 76 <rule ref="Generic.Files.LineLength">
Chris@0 77 <exclude name="Generic.Files.LineLength.TooLong"/>
Chris@0 78 </rule>
Chris@0 79 <rule ref="Generic.Commenting.Todo">
Chris@0 80 <exclude name="Generic.Commenting.Todo.TaskFound"/>
Chris@0 81 <exclude name="Generic.Commenting.Todo.CommentFound"/>
Chris@0 82 </rule>
Chris@0 83
Chris@0 84 <!-- The following sniffs are disabled because Coder is not compliant yet, see
Chris@0 85 https://www.drupal.org/node/2734539 -->
Chris@0 86 <rule ref="PEAR.Commenting.FunctionComment.MissingParamComment">
Chris@0 87 <exclude-pattern>*/DrupalPractice/Sniffs/CodeAnalysis/VariableAnalysisSniff.php</exclude-pattern>
Chris@0 88 </rule>
Chris@0 89
Chris@0 90 </ruleset>