Skip to content

Commit 5b8bb68

Browse files
committed
Update DevKit
1 parent 50b2f93 commit 5b8bb68

16 files changed

Lines changed: 108 additions & 101 deletions

.github/workflows/deptrac.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
pull_request:
55
branches:
66
- develop
7+
- 'v*'
78
paths:
89
- '**.php'
910
- 'composer.*'
@@ -12,6 +13,7 @@ on:
1213
push:
1314
branches:
1415
- develop
16+
- 'v*'
1517
paths:
1618
- '**.php'
1719
- 'composer.*'
@@ -31,21 +33,20 @@ jobs:
3133
- name: Set up PHP
3234
uses: shivammathur/setup-php@v2
3335
with:
34-
php-version: '8.0'
36+
php-version: '8.1'
3537
tools: phive
3638
extensions: intl, json, mbstring, xml
3739
coverage: none
3840
env:
39-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4042

4143
- name: Get composer cache directory
42-
id: composer-cache
43-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
44+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
4445

4546
- name: Cache composer dependencies
4647
uses: actions/cache@v3
4748
with:
48-
path: ${{ steps.composer-cache.outputs.dir }}
49+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
4950
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5051
restore-keys: ${{ runner.os }}-composer-
5152

.github/workflows/infection.yml

Lines changed: 6 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,6 @@ on:
1010
- 'composer.*'
1111
- 'phpunit*'
1212
- '.github/workflows/infection.yml'
13-
push:
14-
branches:
15-
- develop
16-
- 'v*'
17-
paths:
18-
- '**.php'
19-
- 'composer.*'
20-
- 'phpunit*'
21-
- '.github/workflows/infection.yml'
2213

2314
jobs:
2415
main:
@@ -33,12 +24,12 @@ jobs:
3324
- name: Set up PHP
3425
uses: shivammathur/setup-php@v2
3526
with:
36-
php-version: '8.0'
27+
php-version: '8.1'
3728
tools: infection, phpunit
3829
extensions: intl, json, mbstring, gd, xml, sqlite3
3930
coverage: xdebug
4031
env:
41-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
32+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4233

4334
- name: Set up problem matchers for PHPUnit
4435
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
@@ -47,13 +38,12 @@ jobs:
4738
uses: mheap/phpunit-matcher-action@v1
4839

4940
- name: Get composer cache directory
50-
id: composer-cache
51-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
41+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
5242

5343
- name: Cache composer dependencies
5444
uses: actions/cache@v3
5545
with:
56-
path: ${{ steps.composer-cache.outputs.dir }}
46+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
5747
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5848
restore-keys: ${{ runner.os }}-composer-
5949

@@ -65,10 +55,7 @@ jobs:
6555
composer update --no-progress --no-interaction --prefer-dist --optimize-autoloader
6656
fi
6757
68-
- name: Test with PHPUnit
69-
run: vendor/bin/phpunit --teamcity
70-
71-
- name: Mutate with Infection
58+
- name: Run Infection for added files only
7259
run: |
7360
git fetch --depth=1 origin $GITHUB_BASE_REF
74-
infection --threads=2 --skip-initial-tests --coverage=build/phpunit --git-diff-base=origin/$GITHUB_BASE_REF --git-diff-filter=AM --logger-github --ignore-msi-with-no-mutations
61+
infection --threads=max --git-diff-lines --git-diff-base=origin/$GITHUB_BASE_REF --ignore-msi-with-no-mutations --only-covered --logger-github

.github/workflows/phpcpd.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
- name: Setup PHP
3030
uses: shivammathur/setup-php@v2
3131
with:
32-
php-version: '8.0'
32+
php-version: '8.1'
3333
tools: phpcpd
3434
extensions: dom, mbstring
3535
coverage: none

.github/workflows/phpcsfixer.yml

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,9 @@ on:
1818

1919
jobs:
2020
build:
21-
name: PHP ${{ matrix.php-versions }} Coding Standards
21+
name: Coding Standards
2222
runs-on: ubuntu-latest
2323
if: "!contains(github.event.head_commit.message, '[ci skip]')"
24-
strategy:
25-
fail-fast: false
26-
matrix:
27-
php-versions: ['7.4', '8.0', '8.1']
2824

2925
steps:
3026
- name: Checkout
@@ -33,20 +29,19 @@ jobs:
3329
- name: Set up PHP
3430
uses: shivammathur/setup-php@v2
3531
with:
36-
php-version: ${{ matrix.php-versions }}
32+
php-version: '8.1'
3733
extensions: json, tokenizer
3834
coverage: none
3935
env:
40-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
36+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4137

4238
- name: Get composer cache directory
43-
id: composer-cache
44-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
39+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
4540

4641
- name: Cache composer dependencies
4742
uses: actions/cache@v3
4843
with:
49-
path: ${{ steps.composer-cache.outputs.dir }}
44+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
5045
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5146
restore-keys: ${{ runner.os }}-composer-
5247

.github/workflows/phpstan.yml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
pull_request:
55
branches:
66
- develop
7+
- 'v*'
78
paths:
89
- '**.php'
910
- 'composer.*'
@@ -12,6 +13,7 @@ on:
1213
push:
1314
branches:
1415
- develop
16+
- 'v*'
1517
paths:
1618
- '**.php'
1719
- 'composer.*'
@@ -26,7 +28,7 @@ jobs:
2628
strategy:
2729
fail-fast: false
2830
matrix:
29-
php-versions: ['7.4', '8.0', '8.1']
31+
php-versions: ['7.4', '8.0', '8.1', '8.2']
3032

3133
steps:
3234
- name: Checkout
@@ -40,16 +42,15 @@ jobs:
4042
extensions: intl, json, mbstring, xml
4143
coverage: none
4244
env:
43-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4446

4547
- name: Get composer cache directory
46-
id: composer-cache
47-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
48+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
4849

4950
- name: Cache composer dependencies
5051
uses: actions/cache@v3
5152
with:
52-
path: ${{ steps.composer-cache.outputs.dir }}
53+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
5354
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5455
restore-keys: ${{ runner.os }}-composer-
5556

.github/workflows/phpunit.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ on:
44
pull_request:
55
branches:
66
- develop
7+
- 'v*'
78
paths:
89
- '**.php'
910
- 'composer.*'
@@ -12,6 +13,7 @@ on:
1213
push:
1314
branches:
1415
- develop
16+
- 'v*'
1517
paths:
1618
- '**.php'
1719
- 'composer.*'
@@ -25,7 +27,7 @@ jobs:
2527
if: "!contains(github.event.head_commit.message, '[ci skip]')"
2628
strategy:
2729
matrix:
28-
php-versions: ['7.4', '8.0', '8.1']
30+
php-versions: ['7.4', '8.0', '8.1', '8.2']
2931

3032
steps:
3133
- name: Checkout
@@ -39,16 +41,15 @@ jobs:
3941
extensions: intl, json, mbstring, gd, xdebug, xml, sqlite3
4042
coverage: xdebug
4143
env:
42-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
44+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4345

4446
- name: Get composer cache directory
45-
id: composer-cache
46-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
47+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
4748

4849
- name: Cache composer dependencies
4950
uses: actions/cache@v3
5051
with:
51-
path: ${{ steps.composer-cache.outputs.dir }}
52+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
5253
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5354
restore-keys: ${{ runner.os }}-composer-
5455

@@ -66,7 +67,7 @@ jobs:
6667
TERM: xterm-256color
6768
TACHYCARDIA_MONITOR_GA: enabled
6869

69-
- if: matrix.php-versions == '8.0'
70+
- if: matrix.php-versions == '8.1'
7071
name: Run Coveralls
7172
continue-on-error: true
7273
run: |

.github/workflows/psalm.yml

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,21 +33,20 @@ jobs:
3333
- name: Setup PHP
3434
uses: shivammathur/setup-php@v2
3535
with:
36-
php-version: '8.0'
36+
php-version: '8.1'
3737
tools: phpstan, phpunit
3838
extensions: intl, json, mbstring, xml
3939
coverage: none
4040
env:
41-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4242

4343
- name: Get composer cache directory
44-
id: composer-cache
45-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
44+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
4645

4746
- name: Cache composer dependencies
4847
uses: actions/cache@v3
4948
with:
50-
path: ${{ steps.composer-cache.outputs.dir }}
49+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
5150
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5251
restore-keys: ${{ runner.os }}-composer-
5352

.github/workflows/rector.yml

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
strategy:
2929
fail-fast: false
3030
matrix:
31-
php-versions: ['7.4', '8.0', '8.1']
31+
php-versions: ['7.4', '8.0', '8.1', '8.2']
3232

3333
steps:
3434
- name: Checkout
@@ -42,16 +42,15 @@ jobs:
4242
extensions: intl, json, mbstring, xml
4343
coverage: none
4444
env:
45-
COMPOSER_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4646

4747
- name: Get composer cache directory
48-
id: composer-cache
49-
run: echo "::set-output name=dir::$(composer config cache-files-dir)"
48+
run: echo "COMPOSER_CACHE_FILES_DIR=$(composer config cache-files-dir)" >> $GITHUB_ENV
5049

5150
- name: Cache composer dependencies
5251
uses: actions/cache@v3
5352
with:
54-
path: ${{ steps.composer-cache.outputs.dir }}
53+
path: ${{ env.COMPOSER_CACHE_FILES_DIR }}
5554
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}-${{ hashFiles('**/composer.lock') }}
5655
restore-keys: ${{ runner.os }}-composer-
5756

@@ -64,6 +63,4 @@ jobs:
6463
fi
6564
6665
- name: Analyze for refactoring
67-
run: |
68-
composer global require --dev rector/rector:^0.12.16
69-
rector process --dry-run --no-progress-bar
66+
run: vendor/bin/rector process --dry-run --no-progress-bar

.php-cs-fixer.dist.php

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,22 @@
1010
__DIR__ . '/src/',
1111
__DIR__ . '/tests/',
1212
])
13-
->exclude('build')
14-
->append([__FILE__]);
13+
->exclude([
14+
'build',
15+
'Views',
16+
])
17+
->append([
18+
__FILE__,
19+
__DIR__ . '/rector.php',
20+
]);
1521

16-
$overrides = [];
22+
$overrides = [
23+
'php_unit_data_provider_name' => false,
24+
'php_unit_data_provider_return_type' => false,
25+
'php_unit_data_provider_static' => false,
26+
// 'declare_strict_types' => true,
27+
// 'void_return' => true,
28+
];
1729

1830
$options = [
1931
'finder' => $finder,

composer-unused.php

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,9 @@
77
use ComposerUnused\ComposerUnused\Configuration\PatternFilter;
88
use Webmozart\Glob\Glob;
99

10-
return static function (Configuration $config): Configuration {
11-
return $config
12-
// ->addNamedFilter(NamedFilter::fromString('symfony/config'))
13-
// ->addPatternFilter(PatternFilter::fromString('/symfony-.*/'))
14-
->setAdditionalFilesFor('codeigniter4/framework', [
15-
...Glob::glob(__DIR__ . '/vendor/codeigniter4/framework/system/Helpers/*.php'),
16-
]);
17-
};
10+
return static fn (Configuration $config): Configuration => $config
11+
// ->addNamedFilter(NamedFilter::fromString('symfony/config'))
12+
// ->addPatternFilter(PatternFilter::fromString('/symfony-.*/'))
13+
->setAdditionalFilesFor('codeigniter4/framework', [
14+
...Glob::glob(__DIR__ . '/vendor/codeigniter4/framework/system/Helpers/*.php'),
15+
]);

0 commit comments

Comments
 (0)