-
Notifications
You must be signed in to change notification settings - Fork 1k
Description
Bug Report
This may not be a bug per se, but a possible failure on my part to wrangle WP-CLI correctly, or it may be a quirk of the environment in which WP-CLI is operating. I'm not certain, which is why I'm submitting this issue.
Describe the current, buggy behavior
When runing WP-CLI in a custom Docker container via GitHub Actions, commands such as wp plugin list display their output without the expected table formatting (the pluses and minuses). Here's sample output:
name version update_version status
easy-wp-smtp 2.11.0 2.13.1 inactive
query-monitor 3.18.0 3.20.2 inactive
wpforms-lite 1.9.8.4 1.9.8.7 inactive
It may be hard to discern from the text above, but the output is tab-separated.
I *want* the "pluses and minuses" formatting to be rendered in order for it to be converted into a Markdown-compatible table (to include it as part of the GitHub Actions Job Summary).
I have tried explicitly setting the --format parameter to "table," and that has not been successful.
I have also tried setting the $SHELL_PIPE environment variable (official documentation) to "0", and that has not been successful, either.
I was poking around some of the WP-CLI source for the Shell::isPiped() method, and I suspect it has something to do with the fact that when it's running via Docker, WP-CLI doesn't think it's running in a proper TTY and renders an Ascii() object instead of a Tabular() object (in the Table object). But this is a little over my head.
Let us know what environment you are running this on
OS: Linux 6.11.0-1018-azure wp-cli/ideas#18~24.04.1-Ubuntu SMP Sat Jun 28 04:46:03 UTC 2025 x86_64
Shell:
PHP binary: /usr/bin/php83
PHP version: 8.3.14
php.ini used: /etc/php83/php.ini
MySQL binary:
MySQL version:
SQL modes:
WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli
WP-CLI vendor dir: phar://wp-cli.phar/vendor
WP_CLI phar path: phar:///usr/local/bin/wp
WP-CLI packages dir:
WP-CLI cache dir: /github/home/.wp-cli/cache
WP-CLI global config: /root/.wp-cli/config.yml
WP-CLI project config:
WP-CLI version: 2.12.0