Skip to content

Commit 6728d0f

Browse files
authored
Merge pull request #136 from phil-davis/php-8.4-in-ci
Add PHP 8.4 to CI
2 parents 8c2a394 + d8e007b commit 6728d0f

File tree

3 files changed

+16
-6
lines changed

3 files changed

+16
-6
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,16 @@ jobs:
1414
matrix:
1515
php-versions: ['8.0', '8.1', '8.2', '8.3']
1616
coverage: ['pcov']
17+
code-style: ['no']
1718
code-analysis: ['no']
1819
include:
1920
- php-versions: '7.4'
2021
coverage: 'none'
22+
code-style: 'yes'
23+
code-analysis: 'yes'
24+
- php-versions: '8.4'
25+
coverage: 'pcov'
26+
code-style: 'yes'
2127
code-analysis: 'yes'
2228
steps:
2329
- name: Checkout
@@ -48,8 +54,8 @@ jobs:
4854
run: composer install --no-progress --prefer-dist --optimize-autoloader
4955

5056
- name: Code Analysis (PHP CS-Fixer)
51-
if: matrix.code-analysis == 'yes'
52-
run: php vendor/bin/php-cs-fixer fix --dry-run --diff
57+
if: matrix.code-style == 'yes'
58+
run: PHP_CS_FIXER_IGNORE_ENV=true php vendor/bin/php-cs-fixer fix --dry-run --diff
5359

5460
- name: Code Analysis (PHPStan)
5561
if: matrix.code-analysis == 'yes'

.php-cs-fixer.dist.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@
1010
$config->setRules([
1111
'@PSR1' => true,
1212
'@Symfony' => true,
13+
'nullable_type_declaration' => [
14+
'syntax' => 'question_mark',
15+
],
16+
'nullable_type_declaration_for_default_null_value' => true,
1317
]);
1418

1519
return $config;

composer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,19 +46,19 @@
4646
}
4747
},
4848
"require-dev": {
49-
"friendsofphp/php-cs-fixer": "^3.56",
50-
"phpstan/phpstan": "^1.11",
49+
"friendsofphp/php-cs-fixer": "^3.64",
50+
"phpstan/phpstan": "^1.12",
5151
"phpstan/phpstan-phpunit": "^1.4",
5252
"phpstan/phpstan-strict-rules": "^1.6",
53-
"phpstan/extension-installer": "^1.3",
53+
"phpstan/extension-installer": "^1.4",
5454
"phpunit/phpunit" : "^9.6"
5555
},
5656
"scripts": {
5757
"phpstan": [
5858
"phpstan analyse lib tests"
5959
],
6060
"cs-fixer": [
61-
"php-cs-fixer fix"
61+
"PHP_CS_FIXER_IGNORE_ENV=true php-cs-fixer fix"
6262
],
6363
"phpunit": [
6464
"phpunit --configuration tests/phpunit.xml"

0 commit comments

Comments
 (0)