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/php-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# Run PHPCS, PHPStan, and PHPUnit in a single job.
#
# Each check runs only when the project is configured for it, so this file is
# safe to sync to a repository that has only some of them. A check the project
# is configured for but cannot run is reported on the pull request rather than
# failed.
#
# This file is managed in https://github.com/happyprime/projects
name: PHP checks

on:
push:
branches:
- trunk
- develop
pull_request:
branches:
- trunk
- develop

# The consolidated workflow comments on the pull request when a project is
# configured for a check it cannot run. A workflow level permissions block caps
# what a reusable workflow receives, so the write scope is granted here.
permissions:
contents: read
pull-requests: write

jobs:
call-workflow:
uses: happyprime/workflows/.github/workflows/php-checks.yml@trunk
with:
php-version: '8.4'
wp-versions: 'latest trunk'
secrets:
composer-auth-token: ${{ secrets.COMPOSER_AUTH_TOKEN }}
21 changes: 0 additions & 21 deletions .github/workflows/phpcs.yml

This file was deleted.

21 changes: 18 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,27 @@
}
},
"require-dev": {
"happyprime/coding-standards": "^0.0.3",
"phpcompatibility/php-compatibility": "dev-develop as 9.99.99"
"happyprime/coding-standards": "*",
"phpcompatibility/php-compatibility": "9.99.9"
},
"scripts": {
"phpcs": "vendor/bin/phpcs",
"phpcbf": "vendor/bin/phpcbf",
"phpstan": "vendor/bin/phpstan analyse --memory-limit=2048M"
}
},
"repositories": [
{
"type": "package",
"package": {
"name": "phpcompatibility/php-compatibility",
"type": "phpcodesniffer-standard",
"version": "9.99.9",
"source": {
"url": "https://github.com/PHPCompatibility/PHPCompatibility.git",
"type": "git",
"reference": "9f7142356b5674164a6f6dbe12a7a1bcc632db21"
}
}
}
]
}
Loading
Loading