From 73032a283d84755ada54e8f23fc94599c89d684d Mon Sep 17 00:00:00 2001 From: Sergei Predvoditelev Date: Fri, 3 May 2024 11:07:50 +0300 Subject: [PATCH 1/2] Improve CI --- .github/PULL_REQUEST_TEMPLATE.md | 1 - .github/workflows/bc.yml | 23 +++++++++++++++++-- .github/workflows/build.yml | 5 +++- .../workflows/composer-require-checker.yml | 3 ++- .github/workflows/mutation.yml | 3 ++- composer.json | 2 +- 6 files changed, 30 insertions(+), 7 deletions(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 4a3e8ac..6be5d58 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -3,4 +3,3 @@ | Is bugfix? | ✔️/❌ | New feature? | ✔️/❌ | Breaks BC? | ✔️/❌ -| Fixed issues | comma-separated list of tickets # fixed by the PR, if any diff --git a/.github/workflows/bc.yml b/.github/workflows/bc.yml index ba3e9ef..f8cc564 100644 --- a/.github/workflows/bc.yml +++ b/.github/workflows/bc.yml @@ -1,6 +1,25 @@ on: - - pull_request - - push + pull_request: + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + - 'infection.json.dist' + - 'phpunit.xml.dist' + - 'psalm.xml' + push: + branches: ['master'] + paths-ignore: + - 'docs/**' + - 'README.md' + - 'CHANGELOG.md' + - '.gitignore' + - '.gitattributes' + - 'infection.json.dist' + - 'phpunit.xml.dist' + - 'psalm.xml' name: backwards compatibility diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8506ea1..e96052e 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -10,6 +10,7 @@ on: - 'psalm.xml' push: + branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -24,8 +25,10 @@ name: build jobs: phpunit: uses: yiisoft/actions/.github/workflows/phpunit.yml@master + secrets: + codecovToken: ${{ secrets.CODECOV_TOKEN }} with: os: >- ['ubuntu-latest', 'windows-latest'] php: >- - ['8.0', '8.1'] + ['8.0', '8.1', '8.2', '8.3'] diff --git a/.github/workflows/composer-require-checker.yml b/.github/workflows/composer-require-checker.yml index 6cb4099..5473ec9 100644 --- a/.github/workflows/composer-require-checker.yml +++ b/.github/workflows/composer-require-checker.yml @@ -11,6 +11,7 @@ on: - 'psalm.xml' push: + branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -30,4 +31,4 @@ jobs: os: >- ['ubuntu-latest'] php: >- - ['8.0'] + ['8.0', '8.1', '8.2', '8.3'] diff --git a/.github/workflows/mutation.yml b/.github/workflows/mutation.yml index c1aca98..8150499 100644 --- a/.github/workflows/mutation.yml +++ b/.github/workflows/mutation.yml @@ -9,6 +9,7 @@ on: - 'psalm.xml' push: + branches: ['master'] paths-ignore: - 'docs/**' - 'README.md' @@ -26,6 +27,6 @@ jobs: os: >- ['ubuntu-latest'] php: >- - ['8.1'] + ['8.2'] secrets: STRYKER_DASHBOARD_API_KEY: ${{ secrets.STRYKER_DASHBOARD_API_KEY }} diff --git a/composer.json b/composer.json index 5f20cd0..bfcc133 100644 --- a/composer.json +++ b/composer.json @@ -34,7 +34,7 @@ "rector/rector": "^1.0.0", "roave/infection-static-analysis-plugin": "^1.25", "spatie/phpunit-watcher": "^1.23", - "vimeo/psalm": "^4.30|^5.21", + "vimeo/psalm": "^4.30|^5.24", "yiisoft/di": "^1.2", "yiisoft/psr-dummy-provider": "^1.0", "yiisoft/test-support": "^3.0", From b45d82257cacb7e15bfc02cf8b8c91df34170ecb Mon Sep 17 00:00:00 2001 From: Sergei Predvoditelev Date: Fri, 3 May 2024 11:10:57 +0300 Subject: [PATCH 2/2] fix psalm --- .github/workflows/static.yml | 10 +++++++++- psalm83.xml | 21 +++++++++++++++++++++ 2 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 psalm83.xml diff --git a/.github/workflows/static.yml b/.github/workflows/static.yml index d2a03af..d873c39 100644 --- a/.github/workflows/static.yml +++ b/.github/workflows/static.yml @@ -30,7 +30,7 @@ jobs: os: >- ['ubuntu-latest'] php: >- - ['8.1', '8.2', '8.3'] + ['8.1', '8.2'] psalm80: uses: yiisoft/actions/.github/workflows/psalm.yml@master with: @@ -39,3 +39,11 @@ jobs: ['ubuntu-latest'] php: >- ['8.0'] + psalm83: + uses: yiisoft/actions/.github/workflows/psalm.yml@master + with: + psalm-config: psalm83.xml + os: >- + ['ubuntu-latest'] + php: >- + ['8.3'] diff --git a/psalm83.xml b/psalm83.xml new file mode 100644 index 0000000..ee80eb3 --- /dev/null +++ b/psalm83.xml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + +