<?xml version="1.0"?>
<ruleset name="Some Plus Bulk Manager">
	<description>PHPCS ruleset for Some Plus Bulk Manager plugin.</description>

	<file>.</file>

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

	<rule ref="WordPress">
		<exclude name="WordPress.Files.FileName"/>
	</rule>

	<!-- Define the plugin text domain -->
	<rule ref="WordPress.WP.I18n">
		<properties>
			<property name="text_domain" type="array" value="some-plus-bulk-manager"/>
		</properties>
	</rule>

	<!-- Define the plugin prefix so namespace SomePlusBulkManager is recognized -->
	<rule ref="WordPress.NamingConventions.PrefixAllGlobals">
		<properties>
			<property name="prefixes" type="array" value="SomePlusBulkManager,SPBM,spbm"/>
		</properties>
	</rule>

	<!-- Template files use local variables passed from includes - ignore prefix requirement for variables in templates -->
	<rule ref="WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound">
		<exclude-pattern>templates/*</exclude-pattern>
	</rule>

	<!-- Namespace is already prefixed with SomePlusBulkManager - ignore false positives -->
	<rule ref="WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedNamespaceFound">
		<exclude-pattern>*</exclude-pattern>
	</rule>
</ruleset>
