Skip to content

Pasted text from a clipboard is shown as "[pasted #2 1+ lines]" instead of inline pasting #3532

Closed

Description

@kha84

Description

Hello, opencode devs! I've just downloaded and started to familiarize myself with opencode and I immediately stumbled across two issues.

  1. One is being discussed here - shift+enter keybinding not working #1505 - is that there's no straightforward way to provide multi-line prompts (Ubuntu 24 LTS, default Gnome terminal), apart from CTRL+j

  2. Another is that when I paste some text snippets while composing a prompt, they're pasted like "[pasted Roadmap & Existing Issues #2 1+ lines]" to prompt (instead of a plaintext), which is very annoying.

One might say to overcome both these issues I can prepare my prompts in an external editor - and yes, that is a workaround. But it spoils the overall experience of using the opencode as one and only tool.

OpenCode version

No response

Steps to reproduce

No response

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

Activity

  1. github-actions commented on Oct 29, 2025

    @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.

  2. istarkov commented on Oct 29, 2025

    @istarkov
    Contributor

    You can fix this by adding these lines in your opencode.jsonc

      "experimental": {
        "disable_paste_summary": true,
      },

    Anyway it's really strange default behavior and Im also interesting is it intended

  3. kha84 commented on Oct 29, 2025

    @kha84
    Author

    Thanks for answering @istarkov! The version is 0.15.23 (as per the GitHub it's the latest one).

    How to reproduce is:

    1. copy some small piece of text into a clipboard. In my case it was some points I was making for myself, a sort of TODO list I wanted to give to llm as a prompt:
    - don't forget about one thing
    - don't forget about the other thing
    - do the third thing, but keep in mind the previous two
    - also keep in mind that ...
    - and consider ...
    

    With this snippet you should be able to reproduce it.

    1. paste the contents of a clipboard to a prompt control (in Ubuntu's 24.04 LTS default Gnome terminal the shortcut is CTRL+SHIFT+v). You'll see the effect:
    Image

    The interesting fact is - if you copy just first three lines, they are pasted as a normal text. So I suppose this behavior is somewhat dependent on the amount of characters / tokens being pasted.

    Image
  4. rekram1-node commented on Oct 29, 2025

    @rekram1-node
    Contributor

    This is intentional behavior, if you submit the prompt it expands it.

    In the soon to ship version of opencode using opentui this behavior will be adjusted so that you can expand and edit the contents

  5. kha84 commented on Oct 29, 2025

    @kha84
    Author

    Awesome! Thanks a lot for the explanation

  6. zippeurfou commented on Nov 4, 2025

    @zippeurfou

    I actually liked this features but it seems gone with the 1.X release. Was this intended?

  7. rekram1-node commented on Nov 4, 2025

    @rekram1-node
    Contributor

    @zippeurfou are you talking about ability to disable the paste summary?

  8. zippeurfou commented on Nov 4, 2025

    @zippeurfou

    @rekram1-node thanks for answering. I meant that I liked the fact that when I was pasting clipboard I would see [pasted ...] and not the raw text. However, now I do see the raw text.

  9. rekram1-node commented on Nov 4, 2025

    @rekram1-node
    Contributor

    @zippeurfou hmm what terminal are u in and are u on latest? This doesn't work for u?

    Screen.Recording.2025-11-04.at.10.43.17.AM.mov
  10. zippeurfou commented on Nov 4, 2025

    @zippeurfou

    No it does not @rekram1-node .
    I am on iterm2 on macos
    I am on v1.0.20

    Image

  11. rekram1-node commented on Nov 4, 2025

    @rekram1-node
    Contributor

    @zippeurfou I think it has a minimum # of lines required before it does that. Try pasting a large chunk of text like a code file or soemthing

  12. zippeurfou commented on Nov 4, 2025

    @zippeurfou

    Image
    @rekram1-node maybe this was a bad example but long text does exactly the same.

  13. rekram1-node commented on Nov 4, 2025

    @rekram1-node
    Contributor

    wow weird

  14. rekram1-node commented on Nov 4, 2025

    @rekram1-node
    Contributor

    im gonna close this one and open a separate issue for u

  15. rekram1-node commented on Nov 4, 2025

    @rekram1-node
    Contributor

    disable_paste_summary will be respected in next release

  16. Phalangers commented on Mar 25, 2026

    @Phalangers

    workaround:
    paste your prompt > displays [Pasted 4 lines]
    use the command "open editor" (ctrl+x e) and save > turns the prompt back into text

  17. mrckzgl commented on Sep 28, 2026

    @mrckzgl

    This is intentional behavior, if you submit the prompt it expands it.

    In the soon to ship version of opencode using opentui this behavior will be adjusted so that you can expand and edit the contents

    Which version number is mean with the "soon to ship version ... using opentui"? Is this already released, and how to expand the lines?

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions