Skip to content

Commit 07ec92c

Browse files
committed
GH Actions: simplify the PHPStan workflow
* No need to install via Composer, the `setup-php` action can make PHPStan globally available.
1 parent 1106d65 commit 07ec92c

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

.github/workflows/phpstan.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,13 @@ jobs:
2525
with:
2626
php-version: '7.4'
2727
coverage: none
28-
29-
- name: 'Composer: require PHPStan'
30-
run: composer require --no-update --dev phpstan/phpstan
28+
tools: phpstan
3129

3230
# Install dependencies and handle caching in one go.
31+
# Dependencies need to be installed to make sure the PHPUnit classes are recognized.
3332
# @link https://github.com/marketplace/actions/install-composer-dependencies
3433
- name: Install Composer dependencies
3534
uses: "ramsey/composer-install@v1"
3635

3736
- name: Run PHPStan
38-
run: vendor/bin/phpstan analyse --configuration=phpstan.neon
37+
run: phpstan analyse --configuration=phpstan.neon

0 commit comments

Comments
 (0)