diff --git a/config.md b/config.md index 8f13e931..f4af7dba 100644 --- a/config.md +++ b/config.md @@ -373,6 +373,7 @@ WP-CLI's behavior can be changed at runtime through the use of environment varia * `WP_CLI_STRICT_ARGS_MODE` - Avoid ambiguity by telling WP-CLI to treat any arguments before the command as global, and after the command as local. * `WP_CLI_SUPPRESS_GLOBAL_PARAMS` - Set to `true` to skip showing the global parameters at the end of the help screen. This saves screen estate for advanced users. * `WP_CLI_FORCE_USER_LOGIN` - Set to `1` to force the value provided to the `--user` flag to be interpreted as a login instead of an ID, to get around ambiguous types. +* `WP_CLI_EARLY_REQUIRE` - Load a custom PHP file early on in the bootstrap process. To set an environment variable on demand, simply place the environment variable definition before the WP-CLI command you mean to run. diff --git a/troubleshooting.md b/troubleshooting.md index 6115dcb6..2c226c10 100644 --- a/troubleshooting.md +++ b/troubleshooting.md @@ -37,6 +37,7 @@ If you want to run WP-CLI remotely using SSH, it is required that the command `w * `WP_CLI_PHP_ARGS` – Arguments to pass to the PHP binary when invoking WP-CLI (only works for non-Phar installation). * `WP_CLI_SSH_PRE_CMD` – When using `--ssh=`, perform a command before WP-CLI calls WP-CLI on the remote server. * `WP_CLI_STRICT_ARGS_MODE` – Avoid ambiguity by telling WP-CLI to treat any arguments before the command as global, and after the command as local. +* `WP_CLI_EARLY_REQUIRE` - Load a custom PHP file early on in the bootstrap process. To set an environment variable on demand, you can place the environment variable definition before the WP-CLI command you mean to run (e.g. `EDITOR=vim wp post edit 1`); to overwrite environment variables, use `export VARIABLE=value` in your `~/.bashrc` or `~.zhsrc`.