<?xml version="1.0"?>
<ruleset name="WordPress Coding Standards for Plugins">
	<description>Generally-applicable sniffs for WordPress plugins</description>

	<rule ref="WordPress-Core">
		<exclude name="WordPress.Files.FileName.NotHyphenatedLowercase"/>
		<exclude name="WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned"/>
		<exclude name="Generic.Formatting.MultipleStatementAlignment.NotSameWarning"/>
		<exclude name="WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase"/>
		<exclude name="WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase"/>
		<exclude name="WordPress.NamingConventions.ValidFunctionName.MethodNameInvalid"/>
		<exclude name="WordPress.NamingConventions.ValidVariableName.PropertyNotSnakeCase"/>
		<exclude name="WordPress.PHP.YodaConditions"/>
		<exclude name="Generic.Arrays.DisallowShortArraySyntax"/>
	</rule>

	<rule ref="Generic.Arrays.DisallowLongArraySyntax"/>

	<rule ref="WordPress.WP.I18n">
		<properties>
			<property name="text_domain" type="array" value="wpackio" />
		</properties>
	</rule>
	<rule ref="WordPress.Files.FileName">
		<properties>
			<property name="strict_class_file_names" value="false" />
		</properties>
	</rule>
	<rule ref="WordPress.NamingConventions.ValidVariableName">
		<properties>
			<property name="customPropertiesWhitelist" type="array" value="myMixedCasePropery,AnotherMixedCaseProperty" />
		</properties>
	</rule>
	<rule ref="WordPress.Arrays.MultipleStatementAlignment">
		<properties>
			<property name="exact" value="false" />
		</properties>
	</rule>
	<rule ref="Generic.Formatting.MultipleStatementAlignment">
		<properties>
			<property name="maxPadding" value="10" />
		</properties>
	</rule>

	<rule ref="WordPress-Docs">
		<exclude name="Squiz.Commenting.InlineComment.InvalidEndChar"/>
		<exclude name="Squiz.PHP.CommentedOutCode"/>
		<exclude-pattern>*/tests/phpunit/*</exclude-pattern>
	</rule>


	<!-- Check all PHP files in directory tree by default. -->
	<arg name="extensions" value="php"/>
	<file>.</file>

	<!-- Show sniff codes in all reports -->
	<arg value="ps"/>

	<!-- PHPCompatibility -->
	<config name="testVersion" value="5.6-"/>
	<rule ref="PHPCompatibility"/>

	<exclude-pattern>*/node_modules/*</exclude-pattern>
	<exclude-pattern>*/vendor/*</exclude-pattern>
	<exclude-pattern>*/bower_components/*</exclude-pattern>
	<exclude-pattern>*/dist/*</exclude-pattern>
	<exclude-pattern>*/includes/*</exclude-pattern>
	<exclude-pattern>*/tests/*</exclude-pattern>
</ruleset>
