Merge pull request #2343 from themeum/v4-reviews #2542
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: PHPStan | |
| on: [push, pull_request] | |
| jobs: | |
| phpstan: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v3 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: 8.1 | |
| tools: composer | |
| - name: Install dependencies | |
| run: composer install --no-progress --prefer-dist --no-scripts | |
| # 3. Run PHPStan Full Analysis (Now fast due to cache) | |
| - name: Run PHPStan on Changed Files | |
| run: vendor/bin/phpstan analyse -c phpstan.neon -l 1 $(git --no-pager diff --name-only --diff-filter=MARC | grep -E 'classes/|tests/|ecommerce/|helpers/|includes/|migrations/|models/|traits') |