pedrotroller/php-cs-custom-fixer
Custom fixers for PHP-CS-Fixer. Adds rules like ordering Behat context step definition methods by annotation and method name, with options for detecting context classes. Install via Composer and register the fixers in your .php_cs(.dist) config.
Architecture fit: The package extends PHP-CS-Fixer's ecosystem through custom fixers, aligning perfectly with standard code formatting workflows. It integrates as a dev dependency with minimal architectural impact since PHP-CS-Fixer is already a common tool in PHP projects. The fixers operate at the AST level like official fixers, ensuring compatibility with existing linting pipelines.
Integration feasibility: High feasibility. Installation via Composer is trivial (composer require --dev), and configuration requires only 2-3 lines in .php_cs.dist to register fixers and enable rules. The provided examples demonstrate clear configuration patterns for both direct rule setup and rule set factories.
Technical risk: Significant concerns exist. Zero Packagist dependents indicates negligible real-world usage and community validation. The "2025-09-25" release date is likely a data error but suggests potential maintenance issues. No documented compatibility guarantees for modern PHP-CS-Fixer versions (v3+), and the fixers' logic (e.g., Behat step ordering) may have edge cases not covered in tests. Scrutinizer scores are moderate but don't offset the adoption gap.
Key questions:
Stack fit: Ideal for teams already using PHP-CS-Fixer in CI/CD pipelines. It adds no runtime dependencies and works exclusively in dev environments. Best suited for projects with Behat testing (for order_behat_steps) or strict getter/setter conventions (for ordered_with_getter_and_setter_first). Would not fit projects without existing PHP-CS-Fixer adoption.
Migration path:
.php_cs.dist with fixer registration and rule configurationCompatibility: Must verify PHP-CS-Fixer version constraints in the package's composer.json (not explicitly documented). Likely incompatible with PHP-CS-Fixer v3+ if not updated for the new plugin system. Requires PHP 7.4+ based on typical CS-Fixer requirements, but no explicit versioning is stated. Behat fixer assumes standard context class inheritance.
Sequencing:
How can I help you explore Laravel packages today?