micro-editor / micro-editor/micro
Binding `\u001bd` is buggy
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 29.6k
- Forks
- 1.4k
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 10
Description
Description of the problem or steps to reproduce
I found two different bugs because I was binding \u001bd instead of Alt-d.
VS Code
- Bind
\u001bdtoDeleteWordRight - Open micro in VS Code's integrated terminal and test ⌥+Delete (it works)
- Open and exit
rawmode - Test ⌥+Delete again (it writes
dinstead of performing the action)
If you bind Alt-d instead, this bug doesn't happen.
Ghostty
- Bind
\u001bdtoDeleteWordRight - Open micro in Ghostty, run
rawmode, and press ⌥+Delete - It outputs
EventRaw: d: "\x1bd"
If you bind Alt-d instead, it prints EventKey: Alt-d: "\x1bd".
According to Ghostty's inspector, it is sending Alt-delete as expected.
Specifications
Commit hash: 04c57704
OS: macOS Sequoia 15.1
Terminal: Ghostty
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the VS Code or Ghostty behavior described, comparing the escaped binding \u001bd with Alt-d before and after entering raw mode. Trace the input event handling entry point responsible for distinguishing EventRaw from EventKey; done means the escaped binding consistently triggers DeleteWordRight and is classified like Alt-d.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100