Skip to content

[FEATURE] Add option to disable copy-on-select behavior #15941

Closed as not planned

Description

@trry-hub

Problem

Currently, opencode automatically copies text to clipboard when text is selected in the terminal UI. This behavior may not be desired in all scenarios:

  1. Sometimes users just want to select text to view or highlight it, not copy it
  2. Automatic copy can interfere with the system clipboard when users are working with other content
  3. Some users prefer explicit copy actions (Ctrl+C / Cmd+C) for better control

Proposed Solution

Add a configuration option to disable or control the copy-on-select behavior.

Configuration Example

{
  "copyOnSelect": false
}

Or with more granular control:

{
  "copyOnSelect": {
    "enabled": false,
    "showNotification": true
  }
}

Benefits

  • Gives users more control over clipboard behavior
  • Prevents accidental clipboard overwrites
  • Allows users who prefer explicit copy actions to work more naturally
  • No breaking change - can default to current behavior (true) for backward compatibility

Related Issues

Environment

  • OpenCode version: latest
  • Use case: Terminal UI daily usage

Activity

  1. github-actions commented on Mar 4, 2026

    @github-actions
    Contributor

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

    Please review that issue and consider adding a reaction or comment there instead of opening a new one. If your request has meaningfully different scope or context, please clarify how it differs.

  2. added
    coreAnything pertaining to core functionality of the application (opencode server stuff)
    on Mar 4, 2026
  3. josh-freeman-tradeweb commented on Mar 13, 2026

    @josh-freeman-tradeweb

    This is incredibly frustrating, we need a way to turn this off ASAP.

  4. MauritzFunke commented on Apr 17, 2026

    @MauritzFunke

    I tried opencode this week and this is an issue that bothers me the most. Please implement this feature

  5. assigned and unassigned on Apr 26, 2026
  6. removed
    coreAnything pertaining to core functionality of the application (opencode server stuff)
    on May 3, 2026
  7. winlong commented on May 4, 2026

    @winlong

    I only don't want opencode to give me a notification of "copy to clipboard". So please close the message which bother me a lot.

  8. github-actions commented on Jul 5, 2026

    @github-actions
    Contributor

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

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