Bulk update dependencies #5212
Workflow file for this run
This file contains 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: Lint PHP | |
on: | |
push: | |
# Only run if PHP-related files changed. | |
paths: | |
- '**.php' | |
- 'phpcs.xml.dist' | |
- 'phpmd.xml' | |
- 'phpstan.neon.dist' | |
- 'composer.json' | |
- 'composer.lock' | |
- '.github/workflows/lint-php.yml' | |
branches: | |
- main | |
- release/* | |
pull_request: | |
# Only run if PHP-related files changed. | |
paths: | |
- '**.php' | |
- 'phpcs.xml.dist' | |
- 'phpmd.xml' | |
- 'phpstan.neon.dist' | |
- 'composer.json' | |
- 'composer.lock' | |
- '.github/workflows/lint-php.yml' | |
permissions: | |
contents: read | |
# Cancels all previous workflow runs for pull requests that have not completed. | |
concurrency: | |
# The concurrency group contains the workflow name and the (target) branch name. | |
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
timeout-minutes: 5 | |
steps: | |
- name: Harden Runner | |
uses: step-security/harden-runner@8ca2b8b2ece13480cda6dacd3511b49857a23c09 | |
with: | |
disable-file-monitoring: true | |
egress-policy: block | |
allowed-endpoints: > | |
api.github.com:443 | |
github.com:443 | |
objects.githubusercontent.com:443 | |
packagist.org:443 | |
repo.packagist.org:443 | |
getcomposer.org:443 | |
dl.cloudsmith.io:443 | |
- name: Checkout | |
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 | |
- name: Setup PHP | |
uses: shivammathur/setup-php@72ae4ccbe57f82bbe08411e84e2130bd4ba1c10f | |
with: | |
php-version: '8.0' | |
coverage: none | |
tools: composer, cs2pr | |
- name: Validate composer.json | |
run: composer --no-interaction validate --no-check-all | |
- name: Install PHP dependencies | |
uses: ramsey/composer-install@83af392bf5f031813d25e6fe4cd626cdba9a2df6 | |
with: | |
composer-options: '--prefer-dist --no-progress --no-interaction' | |
- name: Detect coding standard violations (PHPCS) | |
run: vendor/bin/phpcs -q --report=checkstyle --severity=1 --runtime-set ignore_errors_on_exit 1 --runtime-set ignore_warnings_on_exit 1 | cs2pr --graceful-warnings | |
- name: Static Analysis (PHPStan) | |
run: composer phpstan | |
- name: Static Analysis (PHPMD) | |
run: composer phpmd | |
- name: Normalize composer.json | |
run: composer normalize --no-interaction --dry-run |