Skip to content

Comments

Repurpose --quiet flag to suppress automatic REPL output#85

Open
Copilot wants to merge 8 commits intomainfrom
copilot/add-suppress-output-option
Open

Repurpose --quiet flag to suppress automatic REPL output#85
Copilot wants to merge 8 commits intomainfrom
copilot/add-suppress-output-option

Conversation

Copy link
Contributor

Copilot AI commented Feb 12, 2026

Implementation Plan: Suppress Shell Output with --quiet Flag

  • Understand the codebase and existing shell implementation
  • Modify Shell_Command to pass quiet flag to REPL
  • Update REPL class to suppress automatic output when quiet mode is enabled
  • Add documentation for the --quiet flag
  • Create tests for quiet mode functionality
  • Run tests to validate the implementation
  • Address code review feedback (cast quiet flag to boolean)
  • Fix Boris REPL compatibility - only pass quiet to built-in REPL
  • Fix output buffering logic to properly capture output
  • Review and finalize changes
Original prompt

This section details on the original issue you should resolve

<issue_title>Option to suppress output?</issue_title>
<issue_description>## Feature Request

When dealing with complex queries, WP Shell often dumps large volumes of data on to my screen.

For example, running a query with 'posts_per_page'=> 200, will result in hundreds of blog posts being printed. But I only want, say, the GUID.

Describe the solution you'd like

I'd like a command-line option so that wp shell --no-output will only display what I explicitly echo.

Current version:

wp shell
wp> $a = "hello";
=> string(5) "hello"

Proposed version:

wp shell --no-output
wp> $a = "hello";
wp></issue_description>

Comments on the Issue (you are @copilot in this section)

@danielbachhuber We could potentially repurpose the `--quiet` global argument for this.

Feel free to submit a pull request, if you'd like. Here is some guidance on our pull request best practices.</comment_new>
<comment_new>@danielbachhuber
@edent That might be it!</comment_new>


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copilot AI and others added 2 commits February 12, 2026 22:43
Co-authored-by: swissspidy <841956+swissspidy@users.noreply.github.com>
Co-authored-by: swissspidy <841956+swissspidy@users.noreply.github.com>
Copilot AI changed the title [WIP] Add option to suppress output in WP Shell Repurpose --quiet flag to suppress automatic REPL output Feb 12, 2026
Copilot AI requested a review from swissspidy February 12, 2026 22:45
@edent
Copy link

edent commented Feb 12, 2026

@copilot please stop spamming me

@swissspidy
Copy link
Member

Sorry about that! You can turn off notifications in the sidebar.

@codecov
Copy link

codecov bot commented Feb 12, 2026

Codecov Report

❌ Patch coverage is 81.81818% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/Shell_Command.php 60.00% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

This comment was marked as resolved.

Co-authored-by: swissspidy <841956+swissspidy@users.noreply.github.com>

This comment was marked as resolved.

@swissspidy

This comment was marked as resolved.

gemini-code-assist[bot]

This comment was marked as resolved.

Co-authored-by: swissspidy <841956+swissspidy@users.noreply.github.com>

This comment was marked as resolved.

@swissspidy swissspidy marked this pull request as ready for review February 23, 2026 15:00
@swissspidy swissspidy requested a review from a team as a code owner February 23, 2026 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Option to suppress output?

3 participants