opencode在WSL2环境下无法从系统剪贴板粘贴内容到opencode界面(复制功能正常) #9054

Closed
opened 2026-02-16 18:11:31 -05:00 by yindo · 3 comments
Owner

Originally created by @zhanghuachang on GitHub (Feb 11, 2026).

Originally assigned to: @rekram1-node on GitHub.

Description

粘贴功能异常: 无法从系统剪贴板粘贴内容到opencode界面

系统环境

  • 操作系统: Windows 10 (主机) + Ubuntu WSL2 (子系统)
  • WSL版本: WSL2, Ubuntu
  • 显示服务器: X11 (DISPLAY=:0)

其他信息

  • xclip: 已安装
  • Windows clip.exe: 可访问

Plugins

No response

OpenCode version

1.1.56

Steps to reproduce

  1. 在WSL2中启动opencode CLI
  2. 尝试粘贴内容 (Ctrl+Shift+V 或右键粘贴)
  3. 观察操作无响应

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

Originally created by @zhanghuachang on GitHub (Feb 11, 2026). Originally assigned to: @rekram1-node on GitHub. ### Description 粘贴功能异常: 无法从系统剪贴板粘贴内容到opencode界面 系统环境 - 操作系统: Windows 10 (主机) + Ubuntu WSL2 (子系统) - WSL版本: WSL2, Ubuntu - 显示服务器: X11 (DISPLAY=:0) 其他信息 - xclip: 已安装 - Windows clip.exe: 可访问 ### Plugins _No response_ ### OpenCode version 1.1.56 ### Steps to reproduce 1. 在WSL2中启动opencode CLI 2. 尝试粘贴内容 (Ctrl+Shift+V 或右键粘贴) 3. 观察操作无响应 ### Screenshot and/or share link _No response_ ### Operating System _No response_ ### Terminal _No response_
yindo added the windowsbug labels 2026-02-16 18:11:31 -05:00
yindo closed this issue 2026-02-16 18:11:31 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Feb 11, 2026):

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

  • #5879: Clipboard copy in WSL
  • #9999: Clipboard functionality fails in WSL environment due to missing Windows executable paths
  • #9922: Windows & Ubuntu: impossible to paste API key after /connect (Ctrl-V / Ctrl-Shift-V / right-click all fail, no hints)
  • #13088: I can't paste to opencode the clipboard content (recently reported, similar paste issue)

These issues all report clipboard paste problems in WSL/Windows environments. Consolidating related issues helps the maintainers track and fix the root cause more efficiently.

@github-actions[bot] commented on GitHub (Feb 11, 2026): This issue might be a duplicate of existing issues. Please check: - #5879: Clipboard copy in WSL - #9999: Clipboard functionality fails in WSL environment due to missing Windows executable paths - #9922: Windows & Ubuntu: impossible to paste API key after /connect (Ctrl-V / Ctrl-Shift-V / right-click all fail, no hints) - #13088: I can't paste to opencode the clipboard content (recently reported, similar paste issue) These issues all report clipboard paste problems in WSL/Windows environments. Consolidating related issues helps the maintainers track and fix the root cause more efficiently.
Author
Owner

@FurryWolfX commented on GitHub (Feb 11, 2026):

Windows 10 + WSL2, using all default configurations, haven't encountered this issue. The terminal is Windows Terminal.

@FurryWolfX commented on GitHub (Feb 11, 2026): Windows 10 + WSL2, using all default configurations, haven't encountered this issue. The terminal is Windows Terminal.
Author
Owner

@zhanghuachang commented on GitHub (Feb 11, 2026):

Windows 10 + WSL2, using all default configurations, haven't encountered this issue. The terminal is Windows Terminal.

Thanks. I tried using Windows Terminal and Git Bash, and the problem is gone. I was using PowerShell before.

@zhanghuachang commented on GitHub (Feb 11, 2026): > Windows 10 + WSL2, using all default configurations, haven't encountered this issue. The terminal is Windows Terminal. Thanks. I tried using Windows Terminal and Git Bash, and the problem is gone. I was using PowerShell before.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#9054