Skip to content

Commit b1c9200

Browse files
authored
feat: require PHP 8.4 (#445)
1 parent 50e2614 commit b1c9200

15 files changed

Lines changed: 99 additions & 107 deletions

.github/workflows/ci.yml

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,23 +20,16 @@ jobs:
2020
- "locked"
2121
- "highest"
2222
php-version:
23-
- "8.3"
2423
- "8.4"
2524
- "8.5"
2625
composer-version:
27-
- "2.2"
2826
- "2.9"
2927
symfony-version:
3028
- "5.4.*"
3129
- "6.4.*"
3230
- "7.0.*"
3331
- "7.1.*"
3432
- "7.2.*"
35-
exclude:
36-
- php-version: "8.4"
37-
composer-version: "2.2"
38-
- php-version: "8.5"
39-
composer-version: "2.2"
4033

4134
steps:
4235
- name: "Checkout"
@@ -90,15 +83,15 @@ jobs:
9083
run: "composer license:check -- --provider-id=licenses -v"
9184

9285
- name: "Run coding style"
93-
if: ${{ matrix.dependencies == 'locked' && matrix.php-version == '8.3' }}
86+
if: ${{ matrix.dependencies == 'locked' && matrix.php-version == '8.4' }}
9487
run: "composer code-style:check"
9588

9689
- name: "Run PHPStan"
9790
if: ${{ matrix.dependencies == 'locked' }}
9891
run: "composer phpstan"
9992

10093
- name: "Run Rector"
101-
if: ${{ matrix.dependencies == 'locked' && matrix.php-version == '8.3' }}
94+
if: ${{ matrix.dependencies == 'locked' && matrix.php-version == '8.4' }}
10295
run: "composer rector:check"
10396

10497
- name: "Unit tests"

.php-cs-fixer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
->setRules([
1212
'@PER-CS2.0' => true,
1313
'@PER-CS2.0:risky' => true,
14-
'@PHP83Migration' => true,
14+
'@PHP84Migration' => true,
1515
'@DoctrineAnnotation' => true,
1616
'align_multiline_comment' => true,
1717
'array_indentation' => true,

bin/composer-license-checker

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ use Lendable\ComposerLicenseChecker\PackagesProvider\ComposerLicensesPackagesPro
1111

1212
require_once $_composer_autoload_path ?? __DIR__.'/../vendor/autoload.php';
1313

14-
(new LicenseChecker(
14+
new LicenseChecker(
1515
new InMemoryPackagesProviderLocator([
1616
'json' => new ComposerInstalledJsonPackagesProvider(),
1717
'licenses' => new ComposerLicensesPackagesProvider(new SymfonyProcessComposerRunner()),
1818
]),
19-
))->run();
19+
)->run();

composer.json

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
}
1111
],
1212
"require": {
13-
"php": "~8.3.0 || ~8.4.0 || ~8.5.0",
13+
"php": "~8.4.0 || ~8.5.0",
1414
"composer-runtime-api": "^2.2",
1515
"symfony/console": "^5.4 || ^6.0 || ^7.0",
1616
"symfony/process": "^5.4.46 || ^6.4.14 || ^7.1.7"
@@ -19,12 +19,12 @@
1919
"ergebnis/composer-normalize": "^2.43.0",
2020
"lendable/phpunit-extensions": "^0.3",
2121
"php-cs-fixer/shim": "^3.61.1",
22-
"phpstan/phpstan": "^1.11.9",
23-
"phpstan/phpstan-deprecation-rules": "^1.2.0",
24-
"phpstan/phpstan-phpunit": "^1.4.0",
25-
"phpstan/phpstan-strict-rules": "^1.6.0",
22+
"phpstan/phpstan": "^2.0",
23+
"phpstan/phpstan-deprecation-rules": "^2.0",
24+
"phpstan/phpstan-phpunit": "^2.0",
25+
"phpstan/phpstan-strict-rules": "^2.0",
2626
"phpunit/phpunit": "^11.3.0",
27-
"rector/rector": "^1.2.2",
27+
"rector/rector": "^2.0",
2828
"symfony/filesystem": "^6.2"
2929
},
3030
"autoload": {
@@ -47,7 +47,7 @@
4747
"ergebnis/composer-normalize": true
4848
},
4949
"platform": {
50-
"php": "8.3"
50+
"php": "8.4"
5151
},
5252
"sort-packages": true
5353
},

composer.lock

Lines changed: 50 additions & 54 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

phpunit.xml.dist

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
colors="true"
55
beStrictAboutOutputDuringTests="true"
66
failOnRisky="true"
7-
cacheResultFile="tmp/.phpunit.result.cache"
7+
cacheDirectory="tmp/"
88
bootstrap="tests/bootstrap.php">
99

1010
<php>

rector.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,17 @@
66
use Rector\CodeQuality\Rector\Identical\FlipTypeControlToUseExclusiveTypeRector;
77
use Rector\Config\RectorConfig;
88
use Rector\PHPUnit\Set\PHPUnitSetList;
9-
use Rector\Symfony\Set\SymfonySetList;
109

1110
return RectorConfig::configure()
1211
->withPaths([__DIR__.'/src', __DIR__.'/tests', __DIR__.'/bin', __DIR__.'/rector.php'])
1312
->withPHPStanConfigs([__DIR__.'/phpstan-rector.neon'])
1413
->withCache(__DIR__.'/tmp/rector', FileCacheStorage::class)
1514
->withPreparedSets(codeQuality: true)
16-
->withPhpSets(php83: true)
15+
->withComposerBased(symfony: true)
16+
->withPhpSets(php84: true)
1717
->withSets(
1818
[
1919
PHPUnitSetList::PHPUNIT_100,
20-
SymfonySetList::SYMFONY_54,
2120
],
2221
)
2322
->withSkip(

src/LicenseChecker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ protected function execute(InputInterface $input, OutputInterface $output): int
153153
$noDev = $config->ignoreDev || $input->getOption('no-dev') === true;
154154

155155
$this->dispatcher->dispatch(new TraceInformation(\sprintf('Checking project at: %s', $path)));
156-
$this->dispatcher->dispatch(new TraceInformation(\sprintf('Using allow file: %s', \realpath($allowFile))));
156+
$this->dispatcher->dispatch(new TraceInformation(\sprintf('Using allow file: %s', (string) \realpath($allowFile))));
157157
$this->dispatcher->dispatch(new TraceInformation(\sprintf('Using provider with id: %s', $providerId)));
158158
$this->dispatcher->dispatch(new TraceInformation(\sprintf('With dev dependencies: %s', $noDev ? 'no' : 'yes')));
159159

0 commit comments

Comments
 (0)