name: PHP Compatibility on: push: branches: - main pull_request: branches: - main workflow_dispatch: permissions: contents: read jobs: php-syntax: name: PHP ${{ matrix.php-version }} runs-on: ubuntu-latest strategy: fail-fast: false matrix: php-version: - '8.1' - '8.2' - '8.3' - '8.4' - '8.5' steps: - name: Checkout repository uses: actions/checkout@v4 - name: Setup PHP ${{ matrix.php-version }} uses: shivammathur/setup-php@v2 with: php-version: ${{ matrix.php-version }} extensions: mysqli, curl, openssl, gd coverage: none - name: Show PHP version run: php -v - name: Check PHP syntax run: | find . \ -type f \ -name "*.php" \ -not -path "./vendor/*" \ -print0 | xargs -0 -r -n1 php -l