Skip to content

Commit

Permalink
minor #145 use GitHub action for PhpStan (xabbuh)
Browse files Browse the repository at this point in the history
This PR was merged into the 0.3-dev branch.

Discussion
----------

use GitHub action for PhpStan

Commits
-------

4d6ab4c use GitHub action for PhpStan
  • Loading branch information
xabbuh committed Oct 31, 2023
2 parents 9335827 + 4d6ab4c commit 8f81e74
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 17 deletions.
18 changes: 5 additions & 13 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,22 +50,14 @@ jobs:
php-version: '${{ matrix.php-version }}'
coverage: 'none'

- name: 'Get Composer cache directory'
id: 'composer-cache'
run: 'echo "::set-output name=cache-dir::$(composer config cache-files-dir)"'

- name: 'Cache dependencies'
uses: 'actions/cache@v2'
with:
path: '${{ steps.composer-cache.outputs.cache-dir }}'
key: "php-${{ matrix.php-version }}-composer-locked-${{ hashFiles('composer.lock') }}"
restore-keys: 'php-${{ matrix.php-version }}-composer-locked-'

- name: 'Install dependencies'
run: 'composer update --no-progress --prefer-stable'
uses: php-actions/composer@v6

- name: 'Run PhpStan'
run: 'vendor/bin/phpstan analyze --no-progress'
uses: 'php-actions/phpstan@v3'
with:
configuration: 'phpstan.neon'
level: max

tests:
name: 'PHPUnit'
Expand Down
1 change: 0 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
"symfony/property-access": "^6.3"
},
"require-dev": {
"phpstan/phpstan": "^1.7.11",
"symfony/phpunit-bridge": "^6.3",
"symfony/translation": "^6.3"
},
Expand Down
3 changes: 0 additions & 3 deletions phpstan.neon
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
includes:
- phar://vendor/phpstan/phpstan/phpstan.phar/conf/config.levelmax.neon

parameters:
checkGenericClassInNonGenericObjectType: false
checkMissingIterableValueType: false
Expand Down

0 comments on commit 8f81e74

Please sign in to comment.