Skip to content

Commit 8c9b4b8

Browse files
authored
removed-php-cs-fixer-deprecated-rules (#80)
1 parent 374217d commit 8c9b4b8

2 files changed

Lines changed: 24 additions & 15 deletions

File tree

CHANGELOG_PHP.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [2.1.2] - 2026-04-20
8+
9+
### Changed
10+
- php-cs-fixer better support for PHP 8.3.
11+
12+
### Removed
13+
- php-cs-fixer deprecated rules.
14+
715
## [2.1.1] - 2025-07-14
816

917
### Changed

php/rules/php-cs-fixer.dist.php

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,32 @@
1414
'@PhpCsFixer' => true,
1515
'@PhpCsFixer:risky' => true,
1616
// '@PSR2' => true, // cool, but add break lines on every fucntion with 1+ params
17-
'@PHPUnit60Migration:risky' => true,
1817
'array_syntax' => ['syntax' => 'short'],
18+
'comment_to_phpdoc' => [
19+
'ignored_tags' => [
20+
// code coverage don't work with phpdoc, so we need to ignore these tags
21+
'codeCoverageIgnoreStart',
22+
'codeCoverageIgnoreEnd',
23+
],
24+
],
1925
'general_phpdoc_annotation_remove' => [
2026
'annotations' => [
2127
'expectedException', 'expectedExceptionMessage', 'expectedExceptionMessageRegExp'
2228
],
2329
],
30+
'method_argument_space' => [
31+
'on_multiline' => 'ignore'
32+
],
2433
'no_useless_return' => true,
2534
'simplified_null_return' => true,
35+
'static_lambda' => false,
36+
'string_implicit_backslashes' => true,
37+
'trailing_comma_in_multiline' => [
38+
'elements' => ['arguments', 'arrays', 'parameters']
39+
],
40+
'use_arrow_functions' => true,
2641
'backtick_to_shell_exec' => true,
2742
'multiline_comment_opening_closing' => true,
28-
'escape_implicit_backslashes' => true,
2943
'ternary_to_null_coalescing' => true,
3044
'concat_space' => ['spacing' => 'one'],
3145
'class_definition' => ['single_line' => true, 'single_item_single_line' => true],
@@ -42,25 +56,12 @@
4256
'psr_autoloading' => true,
4357
'phpdoc_order' => true,
4458

45-
/* PHP 7.0 */
46-
'@PHP70Migration' => true,
47-
'@PHP70Migration:risky' => true,
48-
'@PHP71Migration' => true,
49-
'@PHP71Migration:risky' => true,
50-
'@PHP73Migration' => true,
51-
'@PHP74Migration' => true,
52-
'@PHP74Migration:risky' => true,
53-
'@PHP80Migration' => true,
54-
'@PHP80Migration:risky' => true,
55-
'@PHPUnit84Migration:risky' => true,
56-
5759
'phpdoc_to_return_type' => true,
5860
'native_function_invocation' => ['include' => []], // count -> \count (added like Symfony:risky)
5961
'native_constant_invocation' => false, // PHP_EOL -> \PHP_EOL (added like Symfony:risky)
6062
'single_line_throw' => false,
6163
'phpdoc_types_order' => ['null_adjustment' => 'always_last', 'sort_algorithm' => 'none'],
6264
'phpdoc_add_missing_param_annotation' => false,
63-
'use_arrow_functions' => false,
6465

6566
// disable fix php docs on single line like /** @var XXX $xxx */
6667
'phpdoc_to_comment' => false,

0 commit comments

Comments
 (0)