Created
February 4, 2023 21:02
-
-
Save tplesnar/1555c3fc6bf45fbc837fd9dec368c2a6 to your computer and use it in GitHub Desktop.
Revisions
-
tplesnar created this gist
Feb 4, 2023 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,45 @@ <?php declare(strict_types=1); use PhpCsFixer\Config; use PhpCsFixer\Finder; $rules = [ '@PHP74Migration' => true, '@PHP74Migration:risky' => true, '@PHPUnit75Migration:risky' => true, '@PHP80Migration:risky' => true, '@PHP82Migration' => true, '@PhpCsFixer' => true, '@PhpCsFixer:risky' => true, 'general_phpdoc_annotation_remove' => ['annotations' => ['expectedDeprecation']], // one should use PHPUnit built-in method instead 'modernize_strpos' => true, // needs PHP 8+ or polyfill 'no_useless_concat_operator' => [ 'juggle_simple_strings' => true, ], 'declare_parentheses' => true, 'declare_strict_types' => true, ]; $finder = Finder::create() ->in([ __DIR__ . '/app', __DIR__ . '/config', __DIR__ . '/database', __DIR__ . '/resources', __DIR__ . '/routes', __DIR__ . '/tests', ]) ->name('*.php') ->notName('*.blade.php') ->ignoreDotFiles(true) ->ignoreVCS(true); return (new Config()) ->setFinder($finder) ->setRules($rules) ->setRiskyAllowed(true) ->setUsingCache(true);