Skip to content

fix(tui): use pbcopy on macOS for clipboard copy#418

Merged
lsdefine merged 1 commit into
lsdefine:mainfrom
AspasZhang:fix/macos-clipboard-pbcopy
May 18, 2026
Merged

fix(tui): use pbcopy on macOS for clipboard copy#418
lsdefine merged 1 commit into
lsdefine:mainfrom
AspasZhang:fix/macos-clipboard-pbcopy

Conversation

@AspasZhang
Copy link
Copy Markdown
Contributor

Problem

Ctrl+C copy in TUI v2 silently fails on macOS Terminal.app.

Textual's built-in copy_to_clipboard uses OSC 52 escape sequence which is not supported by macOS Terminal.app (acknowledged in Textual source comments).

Fix

Override copy_to_clipboard in the App class to use pbcopy on macOS, with fallback to the default OSC 52 for other platforms.

Testing

  • Verified syntax passes
  • Only 1 file changed, 14 insertions
  • No existing behavior altered for non-macOS platforms

@lsdefine lsdefine merged commit 54f40d9 into lsdefine:main May 18, 2026
RocketLi pushed a commit to RocketLi/GenericAgent that referenced this pull request May 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants