Skip to content

vip dev-env exec

Run a WP-CLI command against a local environment.

Usage

vip dev-env exec [options]

Options

OptionDescription
-h, --help Retrieve a description, examples, and available options for a (sub)command. (default: false)
-v, --version Retrieve the version number of VIP-CLI currently installed on the local machine. (default: false)
-d, --debug [value] Generate verbose output during command execution to help identify or fix errors or bugs.
-s, --slug [value] A unique name for a local environment. Default is “vip-local”.
-f, --force [value] Skip validation for a local environment to be in a running state.
-q, --quiet [value] Suppress informational messages.

Examples

- Run a WP-CLI command against a local environment named "example-site".
* A double dash ("--") must separate the arguments of "vip" from those of the "wp" command.
$ vip dev-env exec --slug=example-site -- wp post list

- Target the WP-CLI command against the network site "example.example-site.vipdev.lndo.site" of a local multisite environment.
$ vip dev-env exec --slug=example-site -- wp user list --url=example.example-site.vipdev.lndo.site

- Run the WP-CLI command "wp shell" against a local environment to open an interactive PHP console.
$ vip dev-env exec --slug=example-site -- wp shell

Last updated: July 07, 2026