arubacao/php-cs-fixer-config
A ready-made PHP-CS-Fixer configuration for Laravel and PHP projects, providing consistent, opinionated code-style rules out of the box. Install it to standardize formatting across your codebase and skip maintaining custom fixer configs yourself.
Architecture fit
Config subclass plus a curated rules array targeting Laravel conventions (PSR-2 lineage plus Laravel-specific rules such as ordered imports, unary operator spacing, concat spacing, blank-line grouping)..php-cs-fixer.php in under an hour. The dependency boundary adds nothing functional.Integration feasibility
composer require --dev arubacao/php-cs-fixer-config, reference its Config class, add a CI step. Low effort, low blast radius, reversible in one commit..php_cs → .php-cs-fixer.php, large rule renames, @PSR12/@PhpCsFixer rulesets, PHP 8 requirement). PHP-CS-Fixer 2.x does not run reliably on PHP 8.1+, and many of its rules do not understand PHP 8 syntax (attributes, enums, readonly, first-class callables, promoted constructor properties). Adopting this package on a modern Laravel stack means either pinning a dead toolchain or fighting constant composer constraints.@PhpCsFixer + @PSR12 plus a handful of overrides covers the gap. There is no capability this package provides that is not now available from maintained sources.Technical risk
composer audit --abandoned=report (or --strict) will fail CI. That is a recurring, low-severity but permanent tax on every build.--fix run against a mature codebase with an unmaintained ruleset is a code-integrity risk.Key questions
laravel preset or @PhpCsFixer? If the delta is a handful of rules, the dependency is unjustifiable.Stack fit
require-dev, CI lint job, optional pre-commit hook. Never in require, never in the production image..php-cs-fixer.php committed in-repo, and depend directly on friendsofphp/php-cs-fixer (or laravel/pint) at a supported version. This keeps the intent, drops the abandoned edge in the graph, and restores upgrade control.Migration path
@PhpCsFixer/@PSR12 and keep only the intentional Laravel deltas..php-cs-fixer.php or pint.json as first-party config with a comment noting provenance.Compatibility
--dry-run --diff on a representative branch before any write.Sequencing
style: prefix, added to .git-blame-ignore-revs) on a quiet branch. Land it fast to minimize rebase pain.--path-mode=intersection against the diff).Maintenance
Support
Scaling
.php-cs-fixer.cache) makes incremental runs cheap. At monorepo scale, run per-package with --path-mode=intersection in CI so PR feedback stays under a minute.Failure modes
composer audit --strict or --abandoned=fail fails the build. Mitigation: don't take the dependency..git-blame-ignore-revs and an isolated commit.Ramp-up
TPM recommendation
Do not integrate the package. Adopt Laravel Pint (Laravel) or @PhpCsFixer + @PSR12 with a small override block (plain PHP), vendoring any genuinely useful rules from this repo's MIT-licensed config with attribution. The functional benefit is identical and available in an afternoon; the dependency buys an archived, zero-dependent, seven-year-stale supply-chain edge in exchange for nothing. Close the evaluation with a documented "vendored, not depended" decision so it isn't re-litigated.
How can I help you explore Laravel packages today?