Skip to content

Update composer.json #42

Update composer.json

Update composer.json #42

Workflow file for this run

# Source: https://github.com/WordPress/WordPress-Coding-Standards/wiki/Running-in-GitHub-Actions
name: phpcs
on:
push:
pull_request:
# Allow manually triggering the workflow.
workflow_dispatch:
# Cancel all previous workflow runs for the same branch that have not yet completed.
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
phpcs:
runs-on: ubuntu-latest
name: PHPCS
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup PHP
uses: "shivammathur/setup-php@v2"
with:
php-version: "latest"
ini-values: "memory_limit=1G"
coverage: none
tools: phpcs
- name: Install Composer dependencies
uses: "ramsey/composer-install@v2"
with:
# Bust the cache at least once a month - output format: YYYY-MM.
custom-cache-suffix: $(date -u "+%Y-%m")
- name: Run PHPCS checks
run: |
find -L . -name '*.php' -print0 | xargs -0 -n 1 -P 4 php -l
./vendor/bin/phpcs -p -s -v -n . --standard=./phpcs.xml --extensions=php