Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 35 additions & 0 deletions .github/workflows/lint-php.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: PHP Lint

on:
push:
branches:
- main
pull_request:
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
lint:
name: PHP ${{ matrix.php }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php: ['7.4', '8.0', '8.1', '8.2', '8.3']

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
tools: php-parallel-lint
coverage: none

- name: Lint PHP files
run: parallel-lint .
29 changes: 29 additions & 0 deletions .github/workflows/wpcs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: WordPress Coding Standards

on:
push:
branches:
- main
pull_request:
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
phpcs:
name: WPCS
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: WPCS check
uses: 10up/wpcs-action@stable
with:
enable_warnings: true
standard: WordPress
only_changed_lines: true
Loading