diff --git a/.github/workflows/basics.yml b/.github/workflows/basics.yml index 966155b8..2ef7146a 100644 --- a/.github/workflows/basics.yml +++ b/.github/workflows/basics.yml @@ -54,6 +54,7 @@ jobs: run: > composer require --no-update --no-scripts --no-interaction squizlabs/php_codesniffer:"dev-master" + phpcsstandards/phpcsextra:"dev-develop" # Install dependencies and handle caching in one go. # @link https://github.com/marketplace/actions/install-composer-dependencies diff --git a/README.md b/README.md index a9992f40..cacf2234 100644 --- a/README.md +++ b/README.md @@ -66,6 +66,7 @@ The `Yoast` standard for PHP_CodeSniffer is comprised of the following: * The `WordPress` ruleset from the [WordPress Coding Standards](https://github.com/WordPress/WordPress-Coding-Standards) implementing the official [WordPress PHP Coding Standards](https://make.wordpress.org/core/handbook/coding-standards/php/), with some [select exclusions](https://github.com/Yoast/yoastcs/blob/develop/Yoast/ruleset.xml#L29-L75). * The [`PHPCompatibilityWP`](https://github.com/PHPCompatibility/PHPCompatibilityWP) ruleset which checks code for PHP cross-version compatibility while preventing false positives for functionality polyfilled within WordPress. * Select additional sniffs taken from [`PHP_CodeSniffer`](https://github.com/squizlabs/PHP_CodeSniffer). +* Select additional sniffs taken from [`PHPCSExtra`](https://github.com/PHPCSStandards/PHPCSExtra). * A number of custom Yoast specific sniffs. Files within version management and dependency related directories, such as the Composer `vendor` directory, are excluded from the scans by default. diff --git a/composer.json b/composer.json index 66b237ba..3874d100 100644 --- a/composer.json +++ b/composer.json @@ -29,6 +29,7 @@ "php-parallel-lint/php-console-highlighter": "^1.0.0", "php-parallel-lint/php-parallel-lint": "^1.3.2", "phpcompatibility/phpcompatibility-wp": "^2.1.4", + "phpcsstandards/phpcsextra": "^1.1.2", "squizlabs/php_codesniffer": "^3.7.2", "wp-coding-standards/wpcs": "^2.3.0" },