Skip to content

WP-CLI command plugin check not found when using with wp-env #351

@eliot-akira

Description

@eliot-akira

I'm having difficulty running wp plugin check when using it with wp-env.

In an existing project, I installed the plugin.

$ npx wp-env run cli wp plugin install plugin-check --activate

Installing Plugin Check (PCP) (0.2.2)
..
Plugin installed successfully.
Activating 'plugin-check'...
Plugin 'plugin-check' activated.
Success: Installed 1 of 1 plugins.

Running it against another installed plugin:

$ npx wp-env run cli wp plugin check example-plugin

Error: 'check' is not a registered subcommand of 'plugin'. See 'wp help plugin' for available subcommands.

Listing available commands, plugin check is not there.

$ npx wp-env run cli wp help plugin

..
  activate              Activates one or more plugins.
  auto-updates          Manages plugin auto-updates.
  deactivate            Deactivates one or more plugins.
..

It seems like a compatibility issue with wp-env, that something more than plugin activation is necessary to register the WP-CLI command. I'll try with an empty project, and see if I can find any clue to solve it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions