GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [FEATURE]: improve TUI clipboard paste and drag-and-drop file handling on Linux · Issue #14555 · anomalyco/opencode

[FEATURE]: improve TUI clipboard paste and drag-and-drop file handling on Linux #14555

New issue
Copy link
New issue
Copy link
Closed
Closed
[FEATURE]: improve TUI clipboard paste and drag-and-drop file handling on Linux#14555
Copy link
Assignees
rekram1-node
Labels
coreAnything pertaining to core functionality of the application (opencode server stuff)linux

Description

@RobertWsp
RobertWsp
opened on Feb 21, 2026
Issue body actions

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Related issues found: #4668 (drag-and-drop), #6331 (Linux paste in Konsole), #10154 (clipboard paste). This feature request covers all three problems with a unified implementation and additionally adds WezTerm-specific DnD support and non-image file attachment handling, which none of the existing issues address.

Describe the enhancement you want to request

The TUI currently has several limitations with paste and drag-and-drop on Linux:

  1. Clipboard only reads PNG — images copied as JPEG, WebP, GIF, or BMP are silently ignored because clipboard.ts hardcodes image/png
  2. No multi-file paste/drop support — dragging multiple files from a file manager (Nautilus, Thunar) pastes raw paths as text instead of attaching them as files
  3. No non-image file attachments — PDFs, SVGs, code files, and directories pasted via path are not recognized as attachments
  4. WezTerm drag-and-drop doesn't work — WezTerm sends DroppedFile events as space-separated, backslash-escaped paths (via quote_dropped_files = "SpacesOnly"), which is a different format from newline-separated paths that other file managers use

Expected behavior: Dragging files from a file manager into the TUI should display virtual tokens ([Image 1], [File: name.ext], [Dir: dirname/]) instead of raw path text. Clipboard paste should support all common image formats.

Proposed solution (implemented in PR #14552):

  • Dynamic MIME discovery in clipboard.ts — probe clipboard for PNG → JPEG → WebP → GIF → BMP in priority order
  • Rewritten onPaste handler — supports newline-separated paths (Nautilus/Thunar), space-separated escaped paths (WezTerm), and single file paths
  • pasteFile() function for non-image attachments
  • shellTokens() parser for WezTerm's escaped filename format

Activity

  1. github-actions
    assigned
    rekram1-node
    on Feb 21, 2026
  2. github-actions
    added
    coreAnything pertaining to core functionality of the application (opencode server stuff)
    linux
    on Feb 21, 2026
  3. github-actions commented on Feb 21, 2026

    @github-actions
    github-actionsBot
    on Feb 21, 2026 – with GitHub Actions
    Contributor
    More actions

    This issue doesn't fully meet our contributing guidelines.

    What needs to be fixed:

    • Feature requests must use the Feature Request template, which requires a verification checkbox confirming you've searched for existing issues
    • The issue title should start with [FEATURE]: (e.g., [FEATURE]: improve TUI clipboard paste and drag-and-drop file handling on Linux)

    Please edit this issue to address the above within 2 hours, or it will be automatically closed.


    This issue might be a duplicate of existing issues. Please check:

    • Images can not be dragged and dropped #4668: Images can not be dragged and dropped (open issue covering drag-and-drop)
    • pasting images doesn't work on konsole, linux #6331: Pasting images doesn't work on konsole, Linux (open issue covering Linux image paste)
    • Image Clipboard Paste Not Working in OpenCode #10154: Image Clipboard Paste Not Working in OpenCode (open issue covering clipboard paste)

    If you believe this was flagged incorrectly, please let a maintainer know.

  4. github-actions
    added
    needs:complianceThis means the issue will auto-close after 2 hours.
    on Feb 21, 2026
  5. RobertWsp
    changed the title [-]feat: improve TUI clipboard paste and drag-and-drop file handling on Linux[/-] [+][FEATURE]: improve TUI clipboard paste and drag-and-drop file handling on Linux[/+] on Feb 21, 2026
  6. github-actions
    removed
    needs:complianceThis means the issue will auto-close after 2 hours.
    on Feb 21, 2026
  7. github-actions commented on Feb 21, 2026

    @github-actions
    github-actionsBot
    on Feb 21, 2026 – with GitHub Actions
    Contributor
    More actions

    Thanks for updating the issue! It now follows the contributing guidelines and feature request template. The compliance label has been removed.

  8. github-actions commented on Apr 23, 2026

    @github-actions
    github-actionsBot
    on Apr 23, 2026 – with GitHub Actions
    Contributor
    More actions

    To stay organized issues are automatically closed after 60 days of no activity. If the issue is still relevant please open a new one.

  9. github-actions
    closed this as completedon Apr 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @rekram1-node
    rekram1-node

Labels

coreAnything pertaining to core functionality of the application (opencode server stuff)linux

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.