๐Ÿ‘ป ghosttyconf

A terminal editor for the Ghostty configuration.
Browse, search and edit every option, with the full documentation next to it.

Release Go 1.24+ Ghostty 1.3 macOS and Linux

ghosttyconf: categories, options and documentation

Ghostty is configured with a plain text file and close to two hundred options. ghosttyconf puts all of them on one screen. It groups the options into categories and shows each one's type, default and current value. Every option gets the editor that fits it. Comments, blank lines and the order of your file stay intact, and after saving, Ghostty reloads the configuration right away. --- ## โœจ Highlights - ๐Ÿ“š **All options, documented.** All 201 options of Ghostty 1.3, in 19 categories, with the documentation of *your* Ghostty version. - ๐ŸŽ› **An editor for every type.** Toggles, choice lists, checklists for flags, number steppers, colors with live swatches, a list editor for repeatable options, the 256-color palette. - ๐ŸŽจ **Theme and font pickers.** Filter more than 460 themes with a live color preview, or pick from the font families Ghostty can find. - โŒจ๏ธ **Key binding editor.** See Ghostty's built-in bindings merged with yours, and change, unbind, restore or add bindings. Record shortcuts straight from the keyboard. - ๐Ÿงท **Your file stays yours.** Comments, blank lines and the order of untouched lines are kept, and changed entries are rewritten in place. - โœ… **Safe saving.** `ghostty +validate-config` checks every save first. The old file is kept as a backup, writes are atomic, and symlinks into dotfile repositories keep working. - ๐Ÿ”„ **Instant apply.** After saving, the running Ghostty reloads its configuration. - ๐Ÿ”Ž **Search, undo, diff.** Search names and documentation, undo step by step, and review all unsaved changes before you save. ## ๐Ÿš€ Installation ### Download a binary Every [release](https://git.micw.org/mike/ghosttyconf/releases) has ready-to-run binaries for macOS and Linux (arm64 and amd64). They need nothing but Ghostty. ```sh # macOS on Apple silicon; for other systems, replace darwin-arm64 with # darwin-amd64, linux-amd64 or linux-arm64 curl -fLo ghosttyconf https://git.micw.org/mike/ghosttyconf/releases/download/1.0.0/ghosttyconf-darwin-arm64 chmod +x ghosttyconf mv ghosttyconf ~/bin/ # or any other directory in your $PATH ``` If you download the binary with a browser, macOS blocks it at first. Remove the quarantine flag with `xattr -d com.apple.quarantine ghosttyconf`. ### Build from source You need [Go](https://go.dev/dl/) 1.24 or newer. ```sh git clone https://git.micw.org/mike/ghosttyconf.git cd ghosttyconf make install # installs ghosttyconf into $(go env GOPATH)/bin ``` `make build` builds `./ghosttyconf` in the source directory instead. ## ๐Ÿ’ก Quick start ```sh ghosttyconf ``` This opens the config file Ghostty itself would load. Pick a category on the left and an option on the right, then press `enter` to edit it. Changes are marked yellow until you save them with `ctrl+s`. Press `?` for help at any time. ```sh ghosttyconf ~/dotfiles/ghostty/config # edit a specific file ghosttyconf --print-path # which file would be edited? ``` ## ๐ŸŽจ Themes with a live preview Editing `theme` opens a picker over all themes Ghostty ships plus your own. Type to filter. The preview shows the highlighted theme's colors before you commit to it, and a note tells you which of your own color settings override the theme.

Theme picker with preview

Fonts work the same way: `font-family` and its bold/italic variants list the families reported by `ghostty +list-fonts`. ## โŒจ๏ธ Key bindings Press `b` to open the key binding editor. It shows every binding that is *active*: Ghostty's built-in defaults merged with the entries in your file. Each one is marked `default`, `changed`, `custom` or `unbound`.

Key binding editor

- **Change any binding**, including built-in ones. Give it another key or another action. - **Unbind** (`d`) a key, **restore** (`r`) Ghostty's default, or **add** (`a`) a new binding. - **Filter** (`/`) by key, action or description. Searching `cmd+d` finds `super+d`. Press `c` to show only your changes. - See the **documentation of every action** with its parameters, and every key that is bound to it. The editor writes the smallest possible set of entries. Moving `new_split:right` from `super+d` to `super+\` becomes ```ini keybind = super+d=unbind keybind = super+\=new_split:right ``` A binding set back to Ghostty's default disappears from your file again. ### ๐Ÿ”ด Recording shortcuts In the binding form, press `ctrl+r` and then the shortcut. ghosttyconf turns on the kitty keyboard protocol while it records, so `โŒ˜`/super combinations arrive too. Several combinations in a row record a sequence such as `ctrl+a>n`. A warning appears if the key already does something else.

Recording a key combination

## ๐Ÿ’พ Saving and reloading `ctrl+s` saves, and `c` shows what is about to change:

Unsaved changes

Every save runs these steps: 1. **Validate.** The new file is checked with `ghostty +validate-config`. If Ghostty complains, you see its messages and can go back or save anyway. 2. **Check the disk.** If another program changed the file since it was loaded, you are asked before anything is overwritten. 3. **Back up.** The first save of a session keeps the previous version as `config.ghostty.bak`. 4. **Write atomically.** The file is written through a temporary file, so it is never half-written. Symlinks are followed and permissions kept. 5. **Reload.** The running Ghostty reloads its configuration, just like `โŒ˜โ‡ง,` / `ctrl+shift+,`. | Platform | How the reload works | | --- | --- | | macOS | Ghostty's AppleScript command `perform action "reload_config"` (needs `macos-applescript = true`, the default) | | Linux | `SIGUSR2` to your Ghostty processes, which the GTK app handles as a reload | Pass `--no-reload` to only save. ## ๐Ÿงญ Keys | Key | Action | | --- | --- | | `โ†‘` `โ†“` / `j` `k` | move | | `โ†` `โ†’` / `tab` | switch between categories and options | | `enter` | edit the selected option | | `space` | toggle a boolean / cycle a choice | | `+` `-` | increase / decrease a number | | `r` / `del` | reset to the default (removes the line) | | `/` | search option names and documentation | | `b` | key binding editor | | `shift+โ†‘` `shift+โ†“` | scroll the documentation | | `u` / `ctrl+z` | undo | | `c` | show unsaved changes | | `p` | hide options for other platforms | | `ctrl+s` | validate, save and reload | | `?` | help | | `q` | quit | The mouse works too: click to select, click again to edit, and scroll with the wheel. The [user guide](docs/guide.md) lists the keys of every editor. ## โš™๏ธ Command line ```text ghosttyconf [flags] [config-file] --config config file to edit (default: the one Ghostty loads) --ghostty ghostty binary (default: $PATH, then /Applications) --no-reload do not reload Ghostty after saving --offline do not run ghostty; use the built-in option list --print-path print the config file that would be edited and exit --version print the version and exit ``` ## ๐Ÿ”ง How it works The list of options, their types, enum values and flags is generated from Ghostty's source (`src/config/Config.zig`) and built into the binary. At startup, ghosttyconf asks the installed Ghostty for its documentation and defaults (`ghostty +show-config --default --docs`), so the text always matches your version. Themes, fonts, actions and validation also come from the `ghostty` command line. Without Ghostty (`--offline`), the built-in data is used. ## ๐Ÿ“– Documentation - [User guide](docs/guide.md): every editor, key bindings in depth, saving, reloading, troubleshooting - [Development](docs/development.md): project layout, the schema generator, tests and screenshots