<?xml version="1.0"?>
<ruleset name="CustomRuleset">
    <description>Custom ruleset for PHP_CodeSniffer with file and rule exclusions</description>

    <!-- Inherit PSR12 coding standard -->
    <rule ref="PSR12"/>

    <!-- Specify the directory to be scanned (e.g., 'app/' directory) -->
    <file>./</file>

    <!-- Exclude specific files from being checked -->
    <exclude-pattern>public/index.php</exclude-pattern>
    <exclude-pattern>welcome.blade.php</exclude-pattern>

    <!-- Exclude entire vendor directory -->
    <exclude-pattern>vendor/*</exclude-pattern>
    <exclude-pattern>storage/*</exclude-pattern>
    <exclude-pattern>migrations/*</exclude-pattern>
    <exclude-pattern>bootstrap/cache/*</exclude-pattern>

    <!-- Override and disable the line length rule (no warnings for long lines) -->
    <rule ref="Generic.Files.LineLength">
        <properties>
            <!-- Set high values for lineLimit and absoluteLineLimit to effectively disable this rule -->
            <property name="lineLimit" value="200"/>
            <property name="absoluteLineLimit" value="400"/>
        </properties>
    </rule>

    <!-- Exclude the file length rule (disable warnings for files with too many lines) -->
    <exclude name="Generic.Files.ExcessiveFileLength"/>

</ruleset>
