<?xml version="1.0"?>
<ruleset name="WordPress Plugin Coding Standards">
    <description>WordPress Plugin PHPCS Rules</description>

    <!-- What to scan -->
    <file>.</file>

    <!-- Exclude patterns -->
    <exclude-pattern>/vendor/*</exclude-pattern>
    <exclude-pattern>/node_modules/*</exclude-pattern>
    <exclude-pattern>/assets/*</exclude-pattern>
    <exclude-pattern>/tests/*</exclude-pattern>
    <exclude-pattern>/build/*</exclude-pattern>

    <!-- How to scan -->
    <arg value="sp"/> <!-- Show sniff and progress -->
    <arg name="colors"/>
    <arg name="extensions" value="php"/>
    <arg name="parallel" value="8"/>
    <arg name="warning-severity" value="0"/> <!-- Ignore warnings -->

    <!-- Rules: WordPress Coding Standards -->
    <config name="minimum_supported_wp_version" value="5.6"/>

    <rule ref="WordPress">
        <!-- Exclude rules that might be too strict -->
        <exclude name="WordPress.Files.FileName"/>
        <exclude name="WordPress.WP.I18n.MissingTranslatorsComment"/>
        <exclude name="Squiz.Commenting.FileComment.Missing"/>
        <exclude name="Squiz.Commenting.ClassComment.Missing"/>
    </rule>

    <!-- PHP compatibility -->
    <config name="testVersion" value="7.4-"/>
    <rule ref="PHPCompatibilityWP"/>
</ruleset>