0xTerm

A minimal terminal workspace for macOS, drawn by the GPU.


Docs

Shortcuts

KeysAction
⌘Tnew tab
⌘Nnew window
⌘W / ⇧⌘Wclose pane / close tab
⌘D / ⇧⌘Dsplit right / split down
⌘[ / ⌘]previous / next pane
⇧⌘[ / ⇧⌘], ⌃⇥ / ⌃⇧⇥previous / next tab
⌘Bshow or hide the sidebar
⇧⌘Bshow or hide the viewer
⌘Ssave the file in the viewer
⌥⌘Nnew file
⇧⌘Fsearch the folder
⌘Ffind in the open file
⌥⌘Ffind and replace in the viewer
⌘Kclear the terminal
⌘C / ⌘V / ⌘Acopy / paste / select all
⌘-clickopen a path:line or a URL

Right-click a tab to rename or close it. Right-click a pane to split or close it. Right-click the file tree for cd Here, New Tab Here, New File…, Insert Path and Copy Path. Tab and ⇧Tab indent in the viewer; ⌘[ and ⌘] still switch panes there.

Config

0xTerm reads ~/.config/0xterm/config.toml, or $XDG_CONFIG_HOME/0xterm/config.toml when that is set. 0xTerm → Settings… (⌘,) changes most of it for you, writing only the key you changed and keeping your comments. Theme colors are set in the file; Edit config.toml… in Settings opens it. Every key is optional, and anything you leave out keeps the value shown here. Changes apply to open windows as soon as you save.

[app]
icon = ""             # empty is the built-in icon; see Icons

[font]
family = "Menlo"
size = 13.0
line_height = 1.2

[terminal]
shell = ""            # empty means your login shell ($SHELL)
scrollback = 10000
option_as_meta = true # ⌥+key sends ESC+key, for word movement

[theme]
mode = "system"       # or "light" / "dark"

[theme.dark]
background = "#0b0b0b"
foreground = "#e6e6e6"
cursor = "#e6e6e6"
selection = "#264f78"
# ansi = ["#1b1b1b", …16 colors]

[theme.light] takes the same keys. The full defaults are in default.toml.

icon takes a name from the official set, or the file name of your own .svg or .icns in ~/.config/0xterm/icons/. A custom icon is a file inside 0xTerm.app, so codesign --verify --strict reports the app as modified while one is set; Gatekeeper still accepts it, and updates install normally.

How it is built

Bytes travel one way from the shell to the screen, and keys travel back:

zsh ⇄ pty ⇄ oxt-task (reader and writer threads)
              → oxt-session (alacritty_terminal: parser, grid, scrollback)
              → oxt-terminal-view (GPUI on Metal, one snapshot per frame)

A window holds tabs, each tab holds a tree of splits, and each split ends in a pane running a shell. Beside them sits the toolbelt: the file tree, folder search and the viewer. The toolbelt talks to the panes only through events, such as “open this file at this line” or “the working folder changed”.

CrateWhat it does
oxt-taskpty, child process, reader and writer threads, cwd and foreground job
oxt-sessionterminal state; key, paste and mouse encoding; OSC 7
oxt-terminal-viewdraws the grid; selection, links, input
oxt-windowtabs, splits, panes
oxt-toolbeltfile tree, folder search, viewer and editor, Markdown and Mermaid
oxt-configconfig file and themes
appthe oxterm binary: menus, windows, config reload

0xTerm stands on GPUI and gpui-component for the UI, alacritty_terminal for terminal emulation, merman and resvg for diagrams, and ripgrep’s ignore and grep crates for search.

Build from source

cargo run -p oxterm          # run a debug build
cargo test --workspace       # run the tests
packaging/bundle.sh          # build dist/0xTerm.app
packaging/dmg.sh             # build dist/0xTerm-<version>.dmg
packaging/install.sh         # build and install to /Applications

You need current stable Rust and Xcode. After installing Xcode, run sudo xcode-select -s /Applications/Xcode.app and xcodebuild -downloadComponent MetalToolchain.