anomalyco / anomalyco/opencode

Option+Backspace deletes the last word and the empty line in one step, instead of stopping at the empty line first

Open
#43,854 2 comments 0 reactions 1 assignee View on GitHub

@kommander is already working on this.

Since Aug 21, 2026.

Dominant language
TypeScript
Stars
209k
Forks
27.5k
PR merge metrics
PR metrics pending

Description

Description

When I'm on a line with only one word left and I press Option+Backspace, I expect two separate steps:

  1. First press deletes the last word, leaving an empty line.
  2. Second press deletes that empty line and moves the cursor to the end of the line above.

But right now, it skips step 1. One press does both at once — the word is deleted and the cursor jumps straight to the end of the line above, without ever stopping on the empty line.

Plugins

None

OpenCode version

1.18.20

Steps to reproduce
  1. Type two lines, e.g.:
hello this is shlok kohli
i work in this area
  1. Put the cursor at the end of line 2.
  2. Press Option+Backspace repeatedly to delete words on line 2.
  3. When only one word is left on line 2, press Option+Backspace once more.

Expected: Line 2 becomes empty, cursor stays on line 2.
Actual: Line 2 and the newline are both removed in one press, cursor jumps to the end of line 1.

Screenshot and/or share link

https://github.com/user-attachments/assets/787f82c9-002c-4a83-9247-225022cd7949

Operating System

MacOS 26.2.2

Terminal

Ghostty, Alacritty

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.