Skip to content

feat(tui): Editor specific settings on tui.json#32333

Open
trestini wants to merge 6 commits into
anomalyco:devfrom
trestini:feat/editor-tui-settings
Open

feat(tui): Editor specific settings on tui.json#32333
trestini wants to merge 6 commits into
anomalyco:devfrom
trestini:feat/editor-tui-settings

Conversation

@trestini

@trestini trestini commented Jun 14, 2026

Copy link
Copy Markdown

Issue for this PR

Closes #32329

Type of change

  • New feature

What does this PR do?

Add two optional editor settings to tui.json — editor_path and editor_temp_dir — exclusively for the TUI (not the desktop app).

What this changes:

  • editor_path — Lets users override the editor command instead of relying solely on VISUAL/EDITOR environment variables. This is useful when you want a different editor inside opencode TUI than your system default.
  • editor_temp_dir — Lets users choose where temporary editor files (the .md files created when you press Ctrl+E to edit a prompt) are written. Currently these always go to the OS temp directory (os.tmpdir()).

How changes was done:

  • a new 'editor' was added to tui.json schema with above configuration
  • created a new EditorConfig type to reflect the schema
  • used the newly created object to send parameters to openEditor() function, preserving the default values when they aren't configured.

How did you verify your code works?

  • ran bun turbo typecheck
  • made sure that no linter problems was added
  • I used opencode for some days with this change in order to check if there's a side effect

Screenshots / recordings

Not an UI change

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions github-actions Bot added needs:compliance This means the issue will auto-close after 2 hours. and removed needs:compliance This means the issue will auto-close after 2 hours. labels Jun 14, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEATURE]: Editor specific settings on tui.json

1 participant