diff --git a/.php_cs b/.php_cs index 045a0472..d8a1f3ea 100644 --- a/.php_cs +++ b/.php_cs @@ -10,12 +10,31 @@ return PhpCsFixer\Config::create() ->setRiskyAllowed(true) ->setRules( [ - '@PSR2' => true, - 'strict_param' => true, - 'array_syntax' => ['syntax' => 'short'], - 'binary_operator_spaces' => [ + '@PSR2' => true, + 'strict_param' => true, + 'no_php4_constructor' => true, + 'no_extra_blank_lines' => true, + 'no_superfluous_elseif' => true, + 'single_line_comment_style' => false, + 'phpdoc_summary' => false, + 'phpdoc_no_empty_return' => false, + 'simple_to_complex_string_variable' => true, + 'array_syntax' => [ + 'syntax' => 'short', + ], + 'binary_operator_spaces' => [ 'align_double_arrow' => true, ], + 'blank_line_before_statement' => [ + 'statements' => [ + 'declare', + 'if', + 'for', + 'return', + 'throw', + 'try', + ], + ], ] ) ->setFinder($finder); diff --git a/Makefile b/Makefile index 433f96c9..588cef98 100644 --- a/Makefile +++ b/Makefile @@ -70,7 +70,7 @@ test: .PHONY: phpcs phpcs: - @vendor/bin/php-cs-fixer fix --config=.php_cs -v --dry-run --diff + @vendor/bin/php-cs-fixer fix --config=.php_cs -v --diff --dry-run .PHONY: phpstan: