misc_pterodactyl-panel/.php-cs-fixer.dist.php

53 lines
1.3 KiB
PHP
Raw Normal View History

<?php
2021-01-23 20:33:34 +00:00
use PhpCsFixer\Config;
use PhpCsFixer\Finder;
2021-08-16 00:20:36 +00:00
$finder = (new Finder())
->in(__DIR__)
->exclude([
'vendor',
'node_modules',
'storage',
'bootstrap/cache',
])
->notName(['_ide_helper*']);
2021-01-23 21:44:35 +00:00
return (new Config())
2021-01-23 20:33:34 +00:00
->setRiskyAllowed(true)
->setFinder($finder)
2017-08-22 03:06:52 +00:00
->setRules([
'@Symfony' => true,
'@PSR1' => true,
'@PSR2' => true,
2021-01-23 20:33:34 +00:00
'@PSR12' => true,
2017-08-22 03:06:52 +00:00
'align_multiline_comment' => ['comment_type' => 'phpdocs_like'],
'combine_consecutive_unsets' => true,
'concat_space' => ['spacing' => 'one'],
'heredoc_to_nowdoc' => true,
'no_alias_functions' => true,
'no_unreachable_default_argument_value' => true,
'no_useless_return' => true,
'ordered_imports' => [
2021-08-07 23:00:14 +00:00
'sort_algorithm' => 'length',
],
'phpdoc_align' => [
'align' => 'left',
'tags' => [
'param',
'property',
'return',
'throws',
'type',
'var',
],
],
2017-08-22 03:06:52 +00:00
'random_api_migration' => true,
2017-11-05 19:33:42 +00:00
'ternary_to_null_coalescing' => true,
'yoda_style' => [
'equal' => false,
'identical' => false,
'less_and_greater' => false,
],
2021-01-23 20:33:34 +00:00
]);