Skip to content

CLI input issues on WSL Ubuntu: no multiline input and copy/paste not working #7297

Closed as not planned

Description

@Coffe2Cat

Question

Environment

  • OS: Windows 10 / 11
  • WSL: Ubuntu (WSL2)
  • Terminal:
    • Windows Terminal (default profile)
  • OpenCode version: 1.1.4

I installed OpenCode inside WSL Ubuntu, and I’m experiencing some usability issues in the CLI input:

Multiline input is not possible

Pressing Enter, Shift + Enter, or Ctrl + Enter immediately submits the prompt

There is no way to insert a newline while typing

Copy & paste does not work inside the CLI

Right-click paste does nothing

Standard terminal paste shortcuts do not work reliably inside the OpenCode prompt

This makes it very difficult to provide longer prompts or code snippets

Activity

  1. added
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    on Jan 8, 2026
  2. github-actions commented on Jan 8, 2026

    @github-actions
    Contributor

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

    Feel free to ignore if none of these address your specific case.

  3. mxro commented on Jan 21, 2026

    @mxro

    I think I encounter a similar issue. Just posting here to double check if it is related.

    Environment

    • Windows 11
    • Windows Terminal with Git Bash
    • opencode updated today via scoop

    Issue

    Sometimes when I use Ctrl + V, opencode displays Pasted ~xx lines and sometimes it just pastes whatever is in the clipboard as input. The latter is very annoying, since it will submit multiple messages, and often open multiple sessions that start doing mysterious things in the background.

    I haven't found a pattern to this, but these things seem to make the issue less likely:

    • A newly opened opencode
    • When pasting at the beginning of a prompt.
  4. kundeng commented on Jan 24, 2026

    @kundeng

    Environment:

    • OS: Ubuntu 24.04.3 LTS (kernel 6.8.0-90)
    • VS Code: 1.108.2 (c9d77990917f3102ada88be140d28b038d1dd7c7)
    • Shell: /bin/bash
    • OpenCode: 1.1.34

    Repro:

    1. Open VSCode integrated terminal
    2. Run opencode
    3. Try Enter / Shift+Enter / Ctrl+Enter — all submit immediately, no way to insert newline

    Note: Ctrl+J and Ctrl+V are intercepted by VSCode; Shift+Enter doesn’t insert newline here.

  5. xmontero commented on Mar 8, 2026

    @xmontero

    My setup is one step further:

    🟩 Host: Laptop with Win11
    🟩 WSL: Inside Win11 I run WSL with Ubuntu 20.04
    🟩 Docker: Yet the ubuntu in WSL is not the one running the OpenCode. It runs a docker engine. Inside the docker engine I run a container with Ubuntu 24.04
    🟩 OpenCode: It runs in a bash, in the inner ubuntu, which is running in a docker container, which is run by the docker engine running in the outer ubuntu, which in turn runs on the WSL.

    To CLI-in I have this in windows:

    🟧 One small icon with this command: C:\Windows\System32\bash.exe -c /files/bin/sf7 where the script /files/bin/sf7 lives in the WSL filesystem. And sf7 does this: docker exec -u ubuntu -it devel-sf7 bash -c 'cd '${PWD}'; exec ${SHELL}'

    This way, clicking this icon in windows directly enters into a bash.exe (windows) which takes me -with one single click- into the bash inside the "inner ubuntu".

    This setup has been working for years. I can successfully paste there in the terminal with right-click. I can paste in bash, in nano, in Aider, in ClaudeCode... But I can't paste in OpenCode.

    Desired workflow

    I just want to use OpenWhisper to dictate OpenCode what I want. OpenWhisper transcribes and then "pastes" wherever you are (notepad, google drive, or the bash!) but with OpenCode it can't paste what I dictate.

  6. removed
    opentuiThis relates to changes in v1.0, now that opencode uses opentui
    on May 3, 2026
  7. rekram1-node commented on Jun 23, 2026

    @rekram1-node
    Contributor

    Automated: closing question issues.

    GitHub Issues are for bug reports and feature requests only — questions / support are no longer tracked here.

    If this is a bug or feature request, please open a new issue with the appropriate template.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions