mll-lab / php-cs-fixer-config
Shared rules for php-cs-fixer
Installs: 178 345
Dependents: 26
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Requires
- php: ^7.4 || ^8
- friendsofphp/php-cs-fixer: ^3.19.2
- kubawerlos/php-cs-fixer-custom-fixers: ^3.12
Requires (Dev)
- ergebnis/composer-normalize: ^2.13
README
Shared configuration for php-cs-fixer
Installation
composer require --dev mll-lab/php-cs-fixer-config
Usage
In your .php-cs-fixer.php
:
<?php declare(strict_types=1); use function MLL\PhpCsFixerConfig\config; $finder = PhpCsFixer\Finder::create() ->notPath('vendor') ->in(__DIR__) ->name('*.php') ->ignoreDotFiles(true) ->ignoreVCS(true); return config($finder);
Enable risky rules:
use function MLL\PhpCsFixerConfig\risky; return risky($finder);
Override rules:
return config($finder, [ 'some_rule' => false, ]);
Customize config:
return config($finder) ->setHideProgress(true);