Skip to content

Commit dc6976c

Browse files
committed
repair psalm ci
1 parent a0c064a commit dc6976c

File tree

2 files changed

+11
-15
lines changed

2 files changed

+11
-15
lines changed

.github/workflows/static.yml

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ name: static analysis
33
on:
44
pull_request:
55
push:
6-
schedule:
7-
- cron: '0 0 * * *'
86

97
jobs:
108
static-analysis:
@@ -21,23 +19,20 @@ jobs:
2119
uses: actions/checkout@v4
2220

2321
- name: Install PHP ${{ matrix.php }}
24-
uses: shivammathur/setup-php@v2
25-
with:
26-
php-version: ${{ matrix.php }}
27-
tools: composer:v2, cs2pr
28-
coverage: none
29-
30-
- name: Setup PHP
3122
uses: shivammathur/setup-php@v2
3223
with:
3324
php-version: ${{ matrix.php }}
3425
ini-values: error_reporting=E_ALL
3526
coverage: none
3627

28+
- name: Setup problem matchers
29+
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"
30+
31+
- name: Validate composer.json and composer.lock
32+
run: composer validate --ansi --strict
33+
34+
- name: Install dependencies with composer
35+
uses: ramsey/composer-install@v3
36+
3737
- name: Run Psalm Static Analysis
38-
run: |
39-
vendor/bin/psalm \
40-
--shepherd \
41-
--stats \
42-
--output-format=checkstyle \
43-
--php-version=${{ matrix.php }} | cs2pr --graceful-warnings --colorize
38+
run: composer psalm:ci

composer.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
"cs:diff": "php-cs-fixer fix --dry-run -v --diff --show-progress dots",
2929
"cs:fix": "php-cs-fixer fix -v",
3030
"psalm": "psalm",
31+
"psalm:ci": "psalm --output-format=github --shepherd --show-info=false --stats --threads=4",
3132
"psalm:baseline": "psalm --set-baseline=psalm-baseline.xml",
3233
"test": "phpunit --color=always"
3334
},

0 commit comments

Comments
 (0)