Skip to content

Commit 4f180f8

Browse files
committed
Point Composer users to package-command when wp package is missing
`wp-cli/package-command` is a dev dependency since #846, so Composer-based installations of the bundle no longer have `wp package` available. Until now those users only got a generic "'package' is not a registered wp command" error. Declare a hint via `extra.command-hints` so WP-CLI can explain why the command is missing and how to get it back. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G27BNpnRNerEeSGjvefzBf
1 parent 8475849 commit 4f180f8

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

‎composer.json‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@
6464
"extra": {
6565
"branch-alias": {
6666
"dev-main": "2.12.x-dev"
67+
},
68+
"command-hints": {
69+
"package": "The 'package' command is bundled with the WP-CLI Phar, but is an optional dependency of Composer-based installations. Run `composer require wp-cli/package-command` to add it, or manage WP-CLI packages as regular Composer dependencies of your project instead."
6770
}
6871
},
6972
"autoload-dev": {

‎composer.lock‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)