Summary
Please consider adding explicit configuration hooks for external rendering tools in opencode, especially for reviewing diffs, paging long output, and rendering Markdown/document previews.
Examples of tools users may want to opt into:
- external diff tools: delta, difftastic
- external pagers: less, moar, most
- external Markdown renderers: glow, mdcat
Problem
opencode already has a strong built-in TUI renderer and theme system, including settings such as diff_style and theme color keys for diff/Markdown/syntax rendering. However, users who already have a preferred terminal toolchain cannot currently tell opencode to use those tools for specific output surfaces.
For example:
- Installing glow does not make opencode use it for Markdown rendering.
- Installing delta or difftastic does not make opencode use them for reviewing changes.
- Existing git pager settings such as core.pager or PAGER do not appear to be an explicit integration point for opencode's TUI diff/preview rendering.
This means users need to leave the opencode UI or run separate commands when they want their existing renderer/pager/diff workflow.
Proposed solution
Add optional configuration fields for external tools, for example in tui.json or another appropriate config surface:
{
"external_tools": {
"diff": {
"command": "delta",
"args": ["--side-by-side"]
},
"pager": {
"command": "less",
"args": ["-R"]
},
"markdown": {
"command": "glow",
"args": ["-"]
}
}
}
The exact schema is only illustrative. It may be better to split this into narrower settings, such as:
- external_diff_command
- external_pager_command
- external_markdown_renderer
Possible scope
This could be implemented incrementally:
- Support an external diff command for reviewing code changes.
- Respect PAGER / GIT_PAGER / git core.pager for CLI-oriented output where appropriate.
- Support an external Markdown renderer for file/message preview surfaces.
Why this would be useful
- Lets users reuse their existing terminal rendering workflow.
- Makes tools like delta/difftastic/glow useful inside opencode instead of only in separate shell commands.
- Keeps the built-in renderer as the default while allowing advanced users to opt in.
- Helps users who prefer structural diffs, custom pager behavior, or specialized Markdown styling.
Alternatives
- Continue improving the built-in renderer only.
- Add more built-in diff/Markdown display modes.
- Expose only more theme keys for the current renderer.
Those are useful, but they do not cover users who specifically want their existing external renderer/pager/diff tools.
Notes
I searched for existing issues around external diff tools, external pagers, Markdown renderers, delta, difftastic, glow, git pager, and PAGER. I found related issues around built-in diff display modes and IDE diff preview, but did not find a direct request for configurable external renderer/pager/diff tools.
Verification
Summary
Please consider adding explicit configuration hooks for external rendering tools in opencode, especially for reviewing diffs, paging long output, and rendering Markdown/document previews.
Examples of tools users may want to opt into:
Problem
opencode already has a strong built-in TUI renderer and theme system, including settings such as diff_style and theme color keys for diff/Markdown/syntax rendering. However, users who already have a preferred terminal toolchain cannot currently tell opencode to use those tools for specific output surfaces.
For example:
This means users need to leave the opencode UI or run separate commands when they want their existing renderer/pager/diff workflow.
Proposed solution
Add optional configuration fields for external tools, for example in tui.json or another appropriate config surface:
{ "external_tools": { "diff": { "command": "delta", "args": ["--side-by-side"] }, "pager": { "command": "less", "args": ["-R"] }, "markdown": { "command": "glow", "args": ["-"] } } }The exact schema is only illustrative. It may be better to split this into narrower settings, such as:
Possible scope
This could be implemented incrementally:
Why this would be useful
Alternatives
Those are useful, but they do not cover users who specifically want their existing external renderer/pager/diff tools.
Notes
I searched for existing issues around external diff tools, external pagers, Markdown renderers, delta, difftastic, glow, git pager, and PAGER. I found related issues around built-in diff display modes and IDE diff preview, but did not find a direct request for configurable external renderer/pager/diff tools.
Verification