Skip to content

Commit df82773

Browse files
committed
Replace super-linter with custom linters
1 parent a5573f6 commit df82773

File tree

5 files changed

+15
-70
lines changed

5 files changed

+15
-70
lines changed

.github/workflows/php.yml

Lines changed: 7 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ jobs:
115115
uses: shivammathur/setup-php@v2
116116
with:
117117
php-version: ${{ matrix.php-versions }}
118-
extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, openssl, pcre, posix, spl, xml
118+
extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, openssl, pcre, posix, spl, xml, zip
119119
tools: composer
120120
ini-values: error_reporting=E_ALL
121121
coverage: none
@@ -161,9 +161,8 @@ jobs:
161161
with:
162162
# Should be the higest supported version, so we can use the newest tools
163163
php-version: '8.4'
164-
tools: composer, composer-require-checker, composer-unused, phpcs, psalm
165-
# optional performance gain for psalm: opcache
166-
extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, opcache, openssl, pcre, posix, spl, xml
164+
tools: composer, composer-require-checker, composer-unused, phpcs, phpstan
165+
extensions: ctype, date, dom, fileinfo, filter, hash, intl, mbstring, openssl, pcre, posix, spl, xml
167166

168167
- name: Setup problem matchers for PHP
169168
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"
@@ -195,27 +194,13 @@ jobs:
195194
- name: PHP Code Sniffer
196195
run: phpcs
197196

198-
- name: Psalm
199-
continue-on-error: true
200-
run: |
201-
psalm -c psalm.xml \
202-
--show-info=true \
203-
--shepherd \
204-
--php-version=${{ steps.setup-php.outputs.php-version }}
205-
206-
- name: Psalm (testsuite)
197+
- name: PHPStan
207198
run: |
208-
psalm -c psalm-dev.xml \
209-
--show-info=true \
210-
--shepherd \
211-
--php-version=${{ steps.setup-php.outputs.php-version }}
199+
vendor/bin/phpstan analyze -c phpstan.neon
212200
213-
- name: Psalter
201+
- name: PHPStan (testsuite)
214202
run: |
215-
psalm --alter \
216-
--issues=UnnecessaryVarAnnotation \
217-
--dry-run \
218-
--php-version=${{ steps.setup-php.outputs.php-version }}
203+
vendor/bin/phpstan analyze -c phpstan-dev.neon
219204
220205
security:
221206
name: Security checks

phpstan-dev.neon

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
parameters:
2+
level: 9
3+
paths:
4+
- tests

phpstan.neon

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
parameters:
2+
level: 6
3+
paths:
4+
- src

psalm-dev.xml

Lines changed: 0 additions & 18 deletions
This file was deleted.

psalm.xml

Lines changed: 0 additions & 30 deletions
This file was deleted.

0 commit comments

Comments
 (0)