From 210da758907818af6b59e7eea8767d3b32d8a9b3 Mon Sep 17 00:00:00 2001 From: Anthony Tenneriello Date: Thu, 22 Aug 2024 15:32:01 +0200 Subject: [PATCH] feat: no longer supports PHP 7.4 (#29) --- .github/workflows/ci.yml | 2 +- composer.json | 2 +- src/BedrockStreaming.php | 1 + src/Php74.php | 45 ---------------------------------------- 4 files changed, 3 insertions(+), 47 deletions(-) delete mode 100644 src/Php74.php diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2a104d0..2412661 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-20.04 strategy: matrix: - php-version: [ '7.4', '8.0', '8.1' ] + php-version: [ '8.0', '8.1', '8.2', '8.3' ] steps: - uses: actions/checkout@master - uses: shivammathur/setup-php@v2 diff --git a/composer.json b/composer.json index 5dd21ff..41bba8c 100644 --- a/composer.json +++ b/composer.json @@ -12,7 +12,7 @@ } ], "require": { - "php": "^7.4 || ^8.0", + "php": "^8.0", "friendsofphp/php-cs-fixer": "^3.57" }, "autoload": { diff --git a/src/BedrockStreaming.php b/src/BedrockStreaming.php index 6bac667..abd64a2 100644 --- a/src/BedrockStreaming.php +++ b/src/BedrockStreaming.php @@ -42,6 +42,7 @@ public function getRules(): array 'phpdoc_summary' => false, 'single_line_throw' => false, 'yoda_style' => false, + 'trailing_comma_in_multiline' => ['elements' => ['arguments', 'arrays', 'match', 'parameters']], ]; return $rules; diff --git a/src/Php74.php b/src/Php74.php deleted file mode 100644 index c658ef3..0000000 --- a/src/Php74.php +++ /dev/null @@ -1,45 +0,0 @@ -setRiskyAllowed(true); - } - - public function getRules(): array - { - $rules = [ - '@Symfony' => true, - 'array_syntax' => [ - 'syntax' => 'short', - ], - 'no_unreachable_default_argument_value' => false, - 'braces' => [ - 'allow_single_line_closure' => true, - ], - 'heredoc_to_nowdoc' => false, - 'phpdoc_summary' => false, - 'increment_style' => ['style' => 'post'], - 'yoda_style' => false, - 'ordered_imports' => ['sort_algorithm' => 'alpha'], - 'phpdoc_line_span' => [ - 'property' => 'single', - 'const' => 'single', - ], - ]; - - return $rules; - } -}