chore: rely on homeboy wordpress extension for analysis toolchain - #3525
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Removes the duplicated WordPress analysis toolchain from require-dev and relies on Homeboy's wordpress extension, which already ships phpstan, phpstan-wordpress, the WordPress/WP-CLI stubs, php_codesniffer, wpcs, and phpunit. Follows the proven recipe from Extra-Chill/extrachill-users#411. Unblocks on Extra-Chill/homeboy-extensions#2849.
What changed
phpunit/phpunit(^9.6)php-stubs/wordpress-stubs(^6.9)wp-coding-standards/wpcs(^3.4.1)phpcsstandards/phpcsutils(^1.2.3)squizlabs/php_codesniffer(^3.13.6)phpcompatibility/phpcompatibility-wp(^2.1)config.allow-plugins— its only entry wasdealerdirect/phpcodesniffer-composer-installer, which arrives transitively with the extension's wpcs.lint/lint-fixscripts from barephpcs/phpcbf(resolved from the now-nonexistent local vendor/bin) to the extension's binaries viahomeboy extension exec wordpress -- "$HOMEBOY_EXTENSION_PATH/vendor/bin/...", pinned to the extension'shomeboy-wordpress-projectruleset socomposer lintmatches whathomeboy review lintenforces in CI.composer update --no-install(the stale-lock failure mode from extrachill-users#411). Lockpackages-devis now empty; no removed package remains as a locked package.Judgment calls
phpcsstandards/phpcsutilsandphpcompatibility/phpcompatibility-wpwere not in the extrachill-users removal list but are the same duplication: phpcsutils arrives transitively with the extension's wpcs, and nothing in this repo references the PHPCompatibilityWP ruleset (there is no phpcs.xml; grep confirms zeroPHPCompatibilityreferences). Keepingphpcompatibility-wpwould have also kept a local phpcs requirement alive for an unused standard.requireupgrades in the lock — lock regeneration re-resolvedwordpress/agents-api(dev-main snapshot) and minor patch bumps of transitive prod deps. Expected consequence of regenerating rather than hand-editing the lock.Not applicable here
phpstan.neon/phpstan.neon.distin this repo (onlyphpstan-baseline.neon), so no szepeviktorextension.neoninclude to remove.@phpstan-impurecore-function stub file. Thetests/fixtures/*-stubs.phpfiles are runtime test doubles (function_exists-guarded shims for the pure-PHP phpunit smoke harness), not phpstan stubs — left untouched.Verification
composer.jsonparses (json.load).packages-devempty; no banned packages inpackages/packages-dev.php -ltargets.