Course · OpenCode · Living in the TUI
Living in the TUI
With a provider configured and a model picked - the course baseline - the remaining lever is the interface itself. OpenCode is a full-screen, keyboard-first terminal app - the TUI is the product, not a thin skin over some web console - and how fluently you drive it decides whether the agent is a tool you fight or one your hands know without looking.
That matters more here than it would with a tool you bolt onto an editor, and not only for speed. This chapter teaches the TUI as a continuity layer. Real work does not fit in one sitting or one context window: you put the laptop away mid-refactor and want to pick the thread back up exactly where you stood; a second problem breaks while the first is half-fixed and you want both threads separate; the context window fills up under a long session and you need to shed old history and keep the gist. TUI fluency is what makes those moments a few keystrokes instead of re-explaining everything from scratch - sessions across days, branching without losing the original thread, a context that compacts instead of overflowing.
The course’s illustrative project is feedmill: a small self-hosted feed aggregator - a Go CLI plus an HTTP sync server that pulls dozens of RSS, Atom, and JSON feeds, dedupes them, and serves a reading queue you read from the terminal and can run unattended on a cron. It mostly works, it’s thin on docs, and its parsers are a thicket: every feed source is shaped a little differently, and one feed type appears to parse dates wrong. The site ships no starter repository; every page restates the facts it needs, so you can map the moves onto a repo of your own or read along.
What this chapter installs in your hands
Section titled “What this chapter installs in your hands”Working on a codebase like that means living in the TUI for long stretches, which is exactly what these five skills are for:
- The leader key and the command palette - OpenCode hangs most of its actions off a leader key (
ctrl+xby default) and a searchable palette (ctrl+p), so its keymap stays out of your terminal’s way, the actions you use most sit two keystrokes away, and every command stays discoverable (as of October 2026; keybinds documentation) - Juggle and resume sessions - walk away mid-fix and pick it back up later without re-explaining; run two feed-debugging threads side by side without crossing wires
- Undo, redo, and compaction - step a bad edit back, walk it forward again, and let OpenCode summarize a long thread before it overflows so a multi-session refactor keeps going; the summary keeps the thread but can drop fine detail such as an exact error string, which makes it a context decision
- Tab between plan and build - outline an approach to a restructure in the
planagent, which denies the edit tools but does not gate bash unless you add a rule, then switch into thebuildagent that edits freely and execute it, all in one continuous thread (as of October 2026, v1.18.32;planperagent.ts, which the agents documentation describes differently) - Make the TUI yours - rebind the keys to match your muscle memory and pick a theme you can live in
Why learn them against one running project
Section titled “Why learn them against one running project”You could read those as five isolated tips. Don’t. The moves only really click when they’re load-bearing: when there’s a real refactor you don’t want to lose, a real second thread you need to keep separate, a real context window filling up under you. The leader key is trivia until your fingers find it on their own. Session resume is a feature on a docs page until it’s the thing that saves a half-finished parser fix you’d otherwise have re-explained from scratch.
By the end, the TUI stops feeling like a chat window you type into and starts feeling like a second editor pane - one you drive with your hands, that holds your place across sessions and context windows, and that gets out of your way. That fluency is the foundation every later chapter stands on, because every later chapter is also lived inside this window.