Merge pull request #813 from getformwork/feature/invalid-fields-feedback #691
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: Check PHP | |
| on: | |
| push: | |
| branches: | |
| - 2.x | |
| paths: | |
| - '**.php' | |
| pull_request: | |
| branches: | |
| - 2.x | |
| paths: | |
| - '**.php' | |
| permissions: | |
| contents: read | |
| jobs: | |
| check: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup PHP | |
| uses: shivammathur/setup-php@v2 | |
| with: | |
| php-version: '8.3' | |
| tools: composer | |
| - name: Get Composer cache directory | |
| id: composer-cache | |
| run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
| - name: Cache dependencies | |
| uses: actions/cache@v4 | |
| with: | |
| path: ${{ steps.composer-cache.outputs.dir }} | |
| key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} | |
| restore-keys: ${{ runner.os }}-composer- | |
| - name: Validate composer.json and composer.lock | |
| run: composer validate --strict | |
| - name: Install dependencies | |
| run: composer install | |
| - name: Check coding style | |
| run: composer fix:check | |
| - name: Run PHPStan | |
| run: composer phpstan | |
| - name: Run Rector | |
| run: composer rector:check |