From f812048521dce7c03d8f9a494f3b243c428c48a7 Mon Sep 17 00:00:00 2001 From: Nicolas Joubert Date: Thu, 21 Aug 2025 14:29:39 +0200 Subject: [PATCH 1/5] #8 Update rector configuration with minimal version PHP 8.1 --- rector.php | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/rector.php b/rector.php index 72a2408..b19c112 100644 --- a/rector.php +++ b/rector.php @@ -8,23 +8,19 @@ use Rector\ValueObject\PhpVersion; return RectorConfig::configure() - ->withPhpVersion(PhpVersion::PHP_82) + ->withPhpVersion(PhpVersion::PHP_84) ->withPaths([ __DIR__.'/src', __DIR__.'/tests', ]) - ->withPhpSets(php82: true) + ->withPhpSets(php81: true) // here we can define, what prepared sets of rules will be applied - ->withPreparedSets( - deadCode: true, - codeQuality: true - ) + ->withPreparedSets(deadCode: true, codeQuality: true, symfonyCodeQuality: true) + ->withAttributesSets(symfony: true) ->withSets([ - LevelSetList::UP_TO_PHP_82, + LevelSetList::UP_TO_PHP_81, SymfonySetList::SYMFONY_64, - SymfonySetList::SYMFONY_71, SymfonySetList::SYMFONY_CODE_QUALITY, SymfonySetList::SYMFONY_CONSTRUCTOR_INJECTION, - SymfonySetList::ANNOTATIONS_TO_ATTRIBUTES, ]) ; From f27dee1970a2f3a210391dcb2cda2471c75e86ea Mon Sep 17 00:00:00 2001 From: Nicolas Joubert Date: Thu, 21 Aug 2025 14:33:17 +0200 Subject: [PATCH 2/5] #8 Update github workflows with PHP 8.1 to 8.4 for Symfony ^6.4 and PHP 8.2 to 8.4 for Symfony ^7.3 --- .github/workflows/quality.yml | 23 ++++++++++++++++++++--- .github/workflows/test.yml | 24 ++++++++++++++++++++---- 2 files changed, 40 insertions(+), 7 deletions(-) diff --git a/.github/workflows/quality.yml b/.github/workflows/quality.yml index 9f1580f..51412f4 100644 --- a/.github/workflows/quality.yml +++ b/.github/workflows/quality.yml @@ -19,7 +19,7 @@ jobs: - name: Install PHP with extensions uses: shivammathur/setup-php@v2 with: - php-version: '8.2' + php-version: '8.4' coverage: none tools: composer:v2 - name: Install Composer dependencies (locked) @@ -36,7 +36,7 @@ jobs: - name: Install PHP with extensions uses: shivammathur/setup-php@v2 with: - php-version: '8.2' + php-version: '8.4' coverage: none tools: composer:v2 - name: Install Composer dependencies (locked) @@ -53,10 +53,27 @@ jobs: - name: Install PHP with extensions uses: shivammathur/setup-php@v2 with: - php-version: '8.2' + php-version: '8.4' coverage: none tools: composer:v2 - name: Install Composer dependencies (locked) uses: ramsey/composer-install@v3 - name: Rector run: vendor/bin/rector --no-progress-bar --dry-run + + twig-cs-fixer: + name: Twig-CS-Fixer + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Install PHP with extensions + uses: shivammathur/setup-php@v2 + with: + php-version: '8.4' + coverage: none + tools: composer:v2 + - name: Install Composer dependencies (locked) + uses: ramsey/composer-install@v3 + - name: Twig-CS-Fixer + run: vendor/bin/twig-cs-fixer lint --report=github diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2d7e7a4..0e07db0 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -22,11 +22,17 @@ jobs: php-version: - '8.2' - '8.3' + - '8.4' dependencies: [highest] allowed-to-fail: [false] symfony-require: [''] variant: [normal] include: + - php-version: '8.1' + dependencies: highest + allowed-to-fail: false + symfony-require: 6.4.* + variant: symfony/symfony:"6.4.*" - php-version: '8.2' dependencies: highest allowed-to-fail: false @@ -35,8 +41,8 @@ jobs: - php-version: '8.2' dependencies: highest allowed-to-fail: false - symfony-require: 7.1.* - variant: symfony/symfony:"7.1.*" + symfony-require: 7.3.* + variant: symfony/symfony:"7.3.*" - php-version: '8.3' dependencies: highest allowed-to-fail: false @@ -45,8 +51,18 @@ jobs: - php-version: '8.3' dependencies: highest allowed-to-fail: false - symfony-require: 7.1.* - variant: symfony/symfony:"7.1.*" + symfony-require: 7.3.* + variant: symfony/symfony:"7.3.*" + - php-version: '8.4' + dependencies: highest + allowed-to-fail: false + symfony-require: 6.4.* + variant: symfony/symfony:"6.4.*" + - php-version: '8.4' + dependencies: highest + allowed-to-fail: false + symfony-require: 7.3.* + variant: symfony/symfony:"7.3.*" steps: - name: Checkout From 4a3f55a480a85d38dc2d427e1a76ab1483820c28 Mon Sep 17 00:00:00 2001 From: Nicolas Joubert Date: Thu, 21 Aug 2025 14:36:12 +0200 Subject: [PATCH 3/5] #8 Update docker configuration with PHP 8.4 --- .docker/php/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.docker/php/Dockerfile b/.docker/php/Dockerfile index f98c3ba..33dd796 100644 --- a/.docker/php/Dockerfile +++ b/.docker/php/Dockerfile @@ -1,4 +1,4 @@ -FROM php:8.2-fpm-alpine +FROM php:8.4-fpm-alpine ARG UID ARG GID From 9f37f04bd19effaa212c737a7ff3979bd7146c56 Mon Sep 17 00:00:00 2001 From: Nicolas Joubert Date: Thu, 21 Aug 2025 14:39:32 +0200 Subject: [PATCH 4/5] #8 Update composer dependencies for symfony ^6.4|^7.3 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index e31aa57..c288960 100644 --- a/composer.json +++ b/composer.json @@ -33,7 +33,7 @@ "require": { "php": ">=8.1", "cleverage/process-bundle": "^4.0", - "symfony/cache": "^6.4|^7.1" + "symfony/cache": "^6.4|^7.3" }, "require-dev": { "friendsofphp/php-cs-fixer": "*", From 8c9cf6668e1a59df7062c22076a37befe414b811 Mon Sep 17 00:00:00 2001 From: Nicolas Joubert Date: Thu, 21 Aug 2025 14:51:33 +0200 Subject: [PATCH 5/5] #8 Remove twig-cs-fixer from github quality workflows --- .github/workflows/quality.yml | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/.github/workflows/quality.yml b/.github/workflows/quality.yml index 51412f4..a07ce8b 100644 --- a/.github/workflows/quality.yml +++ b/.github/workflows/quality.yml @@ -60,20 +60,3 @@ jobs: uses: ramsey/composer-install@v3 - name: Rector run: vendor/bin/rector --no-progress-bar --dry-run - - twig-cs-fixer: - name: Twig-CS-Fixer - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - - name: Install PHP with extensions - uses: shivammathur/setup-php@v2 - with: - php-version: '8.4' - coverage: none - tools: composer:v2 - - name: Install Composer dependencies (locked) - uses: ramsey/composer-install@v3 - - name: Twig-CS-Fixer - run: vendor/bin/twig-cs-fixer lint --report=github