From 4d6ab4ca5c204db1951c16421d0032aee7139662 Mon Sep 17 00:00:00 2001 From: Christian Flothmann Date: Tue, 31 Oct 2023 12:55:32 +0100 Subject: [PATCH] use GitHub action for PhpStan --- .github/workflows/ci.yaml | 18 +++++------------- composer.json | 1 - phpstan.neon | 3 --- 3 files changed, 5 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index ca0f137..48339ef 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -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' diff --git a/composer.json b/composer.json index 2e69e21..4635e3e 100644 --- a/composer.json +++ b/composer.json @@ -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" }, diff --git a/phpstan.neon b/phpstan.neon index 013f763..8697086 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -1,6 +1,3 @@ -includes: - - phar://vendor/phpstan/phpstan/phpstan.phar/conf/config.levelmax.neon - parameters: checkGenericClassInNonGenericObjectType: false checkMissingIterableValueType: false