| 1 |
<?xml version="1.0"?> |
| 2 |
<ruleset name="IconicWP-Default"> |
| 3 |
<description>Generally-applicable sniffs for Iconic plugins</description> |
| 4 |
|
| 5 |
<!-- Configs --> |
| 6 |
<config name="minimum_supported_wp_version" value="5.2"/> |
| 7 |
<config name="testVersion" value="7.1-"/> |
| 8 |
|
| 9 |
<!-- Excludes --> |
| 10 |
<exclude-pattern>*/dist/*</exclude-pattern> |
| 11 |
<exclude-pattern>*/languages/*</exclude-pattern> |
| 12 |
<exclude-pattern>*/.github/*</exclude-pattern> |
| 13 |
<exclude-pattern>*/wp-admin/*</exclude-pattern> |
| 14 |
<exclude-pattern>*/wp-includes/*</exclude-pattern> |
| 15 |
<exclude-pattern>*/wp-config.php</exclude-pattern> |
| 16 |
<exclude-pattern>*/functions.php</exclude-pattern> |
| 17 |
<exclude-pattern>*/*.asset.php</exclude-pattern> |
| 18 |
<exclude-pattern>*/stubs/*</exclude-pattern> |
| 19 |
|
| 20 |
<!-- Third-party code --> |
| 21 |
<exclude-pattern>*/node_modules/*</exclude-pattern> |
| 22 |
<exclude-pattern>*/vendor/*</exclude-pattern> |
| 23 |
<exclude-pattern>*/vendor-prefixed/*</exclude-pattern> |
| 24 |
|
| 25 |
<!-- Ensure certain file types aren't sniffed --> |
| 26 |
<exclude-pattern>*\.(css|js)</exclude-pattern> |
| 27 |
|
| 28 |
<!-- Rules --> |
| 29 |
<rule ref="WordPress"> |
| 30 |
<exclude name="WordPress.Files.FileName.NotHyphenatedLowercase"/> |
| 31 |
<exclude name="WordPress.Files.FileName.InvalidClassFileName"/> |
| 32 |
</rule> |
| 33 |
|
| 34 |
<rule ref="WordPress-Core"> |
| 35 |
<exclude name="Generic.Arrays.DisallowShortArraySyntax"/> |
| 36 |
<exclude name="WordPress.PHP.YodaConditions"/> |
| 37 |
</rule> |
| 38 |
|
| 39 |
<rule ref="WooCommerce-Core" /> |
| 40 |
<rule ref="PHPCompatibilityWP"/> |
| 41 |
|
| 42 |
<rule ref="WordPress.WP.PostsPerPage"> |
| 43 |
<properties> |
| 44 |
<property name="posts_per_page" value="200"/> |
| 45 |
</properties> |
| 46 |
</rule> |
| 47 |
|
| 48 |
<rule ref="WordPress-Extra"> |
| 49 |
<!-- Don't require punctuation after inline comments --> |
| 50 |
<exclude name="Squiz.Commenting.InlineComment.InvalidEndChar"/> |
| 51 |
|
| 52 |
<!-- Comment punctuation doesn't matter --> |
| 53 |
<exclude name="Squiz.Commenting.FunctionComment.ParamCommentFullStop"/> |
| 54 |
<exclude name="Squiz.Commenting.FunctionComment.ThrowsNoFullStop"/> |
| 55 |
</rule> |
| 56 |
</ruleset> |
| 57 |
|