Skip to content

Commit bd7e8df

Browse files
committed
MAGE-185 Php/CS-FIXER compatibility Update in Algolia for Magento 2.4.4
1 parent 4a0ba1a commit bd7e8df

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

.php_cs renamed to .php-cs-fixer.php

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
/** @var PhpCsFixer\Config $config */
44
if (isset($_SERVER['argv']) && $_SERVER['argv'][3]) {
5-
$config = require dirname($_SERVER['argv'][3], 3) . '/.php_cs.dist';
5+
$config = require dirname($_SERVER['argv'][3], 3) . '/.php-cs-fixer.dist.php';
66
} else {
7-
$config = require __DIR__ . '/../../../.php_cs.dist';
7+
$config = require __DIR__ . '/../../../.php-cs-fixer.dist.php';
88
}
99

1010
$originalRules = $config->getRules();
@@ -14,7 +14,7 @@
1414
// Commented rules are released, but not in the version of PHP CS fixer Magento supports
1515
$extensionRules = [
1616
'blank_line_after_opening_tag' => true,
17-
'blank_line_before_return' => true,
17+
'blank_line_before_statement' => true,
1818
'cast_spaces' => true,
1919
'combine_consecutive_unsets' => true,
2020
'mb_str_functions' => true,
@@ -23,7 +23,7 @@
2323
'no_empty_statement' => true,
2424
'no_multiline_whitespace_around_double_arrow' => true,
2525
'no_short_bool_cast' => true,
26-
'no_short_echo_tag' => true,
26+
'echo_tag_syntax' => true,
2727
// 'no_superfluous_phpdoc_tags' => true,
2828
'no_unneeded_control_parentheses' => true,
2929
'no_unreachable_default_argument_value' => true,
@@ -37,20 +37,23 @@
3737
'not_operator_with_space' => false,
3838
'object_operator_without_whitespace' => true,
3939
'phpdoc_annotation_without_dot' => true,
40+
'general_phpdoc_tag_rename' => true,
41+
'phpdoc_inline_tag_normalizer' => true,
42+
'phpdoc_tag_type' => true,
4043
'phpdoc_inline_tag' => true,
4144
'phpdoc_order' => true,
4245
'phpdoc_scalar' => true,
4346
'phpdoc_separation' => true,
4447
'phpdoc_single_line_var_spacing' => true,
4548
'protected_to_private' => true,
46-
'psr4' => true,
49+
'psr_autoloading' => true,
4750
'short_scalar_cast' => true, // ?
4851
'single_blank_line_before_namespace' => true,
4952
'single_quote' => true,
5053
'space_after_semicolon' => true,
5154
'standardize_not_equals' => true,
5255
'ternary_operator_spaces' => true,
53-
'trailing_comma_in_multiline_array' => true,
56+
'trailing_comma_in_multiline' => true,
5457
'trim_array_spaces' => true,
5558
];
5659

0 commit comments

Comments
 (0)