anomalyco / anomalyco/opencode
[FEATURE]: Add cursor_style configuration support in tui.json
@kommander is already working on this.
Since Jul 26, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Verification
- I searched for existing feature requests.
- I discussed this in Discord (if there's an existing conversation).
Description
OpenCode currently hardcodes terminal escape sequences that force a block cursor shape, ignoring the native terminal cursor configuration (commonly beam/vertical line in Terminal.app, iTerm2, and other emulators). The TUI initialization in @opentui/core sets terminal raw mode and emits default escape sequences that reset user cursor preferences.
Proposed Solution
Expose a cursor_style key in tui.json config that accepts one of three values - beam, underline, or block - and emits the corresponding DECSCUSR escape codes during terminal initialization.
Example config:
{
"$schema": "https://opencode.ai/tui.json",
"cursor_style": "beam"
}
Alternative solutions
- A settings popup in the TUI itself.
- Using an environment variable to configure cursor shape.
Contributor guide
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.
Assessment
This issue has not been assessed yet.