lint.yml 683 B

1234567891011121314151617181920212223242526272829303132333435
  1. name: "PHP Lint"
  2. on:
  3. push:
  4. pull_request:
  5. permissions:
  6. contents: read # to fetch code (actions/checkout)
  7. jobs:
  8. tests:
  9. name: "Lint"
  10. runs-on: ubuntu-latest
  11. strategy:
  12. matrix:
  13. php-version:
  14. - "8.1"
  15. - "8.3"
  16. steps:
  17. - name: "Checkout"
  18. uses: "actions/checkout@v4"
  19. - name: "Install PHP"
  20. uses: "shivammathur/setup-php@v2"
  21. with:
  22. coverage: "none"
  23. extensions: "intl"
  24. ini-values: "memory_limit=-1"
  25. php-version: "${{ matrix.php-version }}"
  26. - name: "Lint PHP files"
  27. run: "find src/ -type f -name '*.php' -print0 | xargs -0 -L1 -P4 -- php -l -f"