Skip to content

Github Action: Add phpcs checks #1

Github Action: Add phpcs checks

Github Action: Add phpcs checks #1

Workflow file for this run

name: Code Standards
on:
pull_request:
jobs:
phpcs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Required for phpcs-changed to compare with base branch
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.1'
tools: composer:v2
- name: Install Dependencies
run: composer install
- name: Run PHPCS on changed files
run: vendor/bin/phpcs-changed --git-base=origin/${{ github.base_ref }} --phpcs-path=vendor/bin/phpcs --standard=.phpcs.xml.dist