Skip to content

Cannot rebind input_submit #26074

Closed as not planned
Closed as not planned

Description

@edwardpeters

Description

(Related to #1505)

EDIT: I played around with it some more and found that adding tab works as expected - but ctrl+j or f1 do not. ctrl+j DID work for newlines, tho, so something is different about input_submit.

I 've been unable to get shift+return to input newlines (using terminator). As a workaround, I'd prefer to simply have "enter" always produce a newline, and use one of the more awkward sequences (ctrl+j) to send. However, the updated bindings do not trigger a submit at all.

Expected Behavior

I expect to be able to rebind input_submit to some other keybinding, and then use unmodified enter as newlines.

Observed Behavior

Some change was recognized, as hitting enter now creates a newline rather than submitting. But the newly added commands (ctrl+j, f1) do not input either; I've found no way to actually send a prompt unless input_submit is bound to return.

(see above, binding input_submit to tab does work.)

Plugins

No response

OpenCode version

1.14.19

Steps to reproduce

  1. Edit tui.json to add:
    "input_submit": "ctrl+j,f1",
    "input_newline": "return",
  1. Launch opencode
  2. Type something
  3. Hit ctrl+j or f1
  4. Be disappointed

Screenshot and/or share link

No response

Operating System

EndeavourOS (6.18.9-arch1-2)

Terminal

terminator 2.1.5

Activity

  1. github-actions commented on May 6, 2026

    @github-actions
    Contributor

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

    For keybind-related issues, please also check our pinned keybinds documentation: #4997

  2. edwardpeters commented on May 6, 2026

    @edwardpeters
    Author

    UPDATE - playing around with it more, I found I can bind input_submit to tab and that works. No idea why f1 and ctrl j do not. ctrl j worked when it was the binding for newline.

    OH but I cannot rebind agent cycle to ctrl+tab... that's fine, I can cycle with shift+tab, but throwing that on the pile

  3. kommander commented on May 11, 2026

    @kommander
    Contributor

    terminator does not properly support key modifiers or kitty keyboard. There have been some workarounds of users in other issues where they configure terminator to send the proper modified key sequence for shift+enter so it works. Unfortunately there is nothing we can do from application side when the terminal does not send key sequences properly.

  4. edwardpeters commented on May 12, 2026

    @edwardpeters
    Author

    @kommander
    I know that's a very common issue, but I think what I'm describing is different. These are key bindings which OpenCode recognizes in some contexts - so Terminator is capturing them - but are not recognized in others. e.g., ctrl+j worked for me for "newline without submit", but when I tried to bind it to "submit", nothing happened. (NOT "enter still caused submit to fire" - when submit was bound to ctrl+j, nothing caused submit to fire.)

  5. github-actions commented on Jul 12, 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.

  6. AlwaysYng commented on Aug 31, 2026

    @AlwaysYng

    To make Enter insert a newline and Ctrl+Enter submit, use:

    {
      "$schema": "https://opencode.ai/tui.json",
      "keybinds": {
        "input_newline": "return",
        "input_submit": "linefeed"
      }
    }

    You can check out the details here

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