# Ghostty Configuration
Personal [[Ghostty]] 1.2.3 terminal emulator setup on macOS. GPU-accelerated, minimal config, ==Catppuccin Mocha== theme to match [[Tmux Configuration|tmux]] and [[Neovim Configuration|Neovim]].
Config file: `~/.config/ghostty/config`
> [!info] What is Ghostty?
> Ghostty is a cross-platform, GPU-accelerated terminal emulator built by Mitchell Hashimoto (HashiCorp co-founder). It uses Metal on macOS for rendering, supports modern terminal features like OSC 52 clipboard, shell integration, and has built-in themes. Config is a flat key-value format (no TOML/YAML/JSON) — settings apply on save, no restart needed.
## Key Settings
| Setting | Value | Why |
|---------|-------|-----|
| Font | `JetBrainsMono Nerd Font Mono` | Icons for neo-tree, lualine, which-key |
| Font size | 14 | Comfortable default |
| Theme | Catppuccin Mocha | Matches tmux and Neovim |
| Window padding | 4px | Slight breathing room |
| Cursor | Block, no blink | Visible and still |
| Shell integration | zsh | Prompt markers, command tracking |
| Clipboard | Read + write + copy-on-select | Seamless clipboard access |
| Mouse | Hide while typing | Less distraction |
## Config File
The full config at `~/.config/ghostty/config`:
```ini
# --- Font ---
font-family = JetBrainsMono Nerd Font Mono
font-size = 14
# --- Theme ---
theme = Catppuccin Mocha
# --- Window ---
window-padding-x = 4
window-padding-y = 4
window-decoration = true
# --- Cursor ---
cursor-style = block
cursor-style-blink = false
# --- Shell integration ---
shell-integration = zsh
# --- Clipboard ---
clipboard-read = allow
clipboard-write = allow
copy-on-select = clipboard
# --- Mouse ---
mouse-hide-while-typing = true
```
> [!tip] Config Format
> Ghostty uses a flat `key = value` format with no file extension. Comments start with `#`. Changes are picked up on save — no restart needed.
## Useful Commands
| Command | Description |
|---------|-------------|
| `ghostty +list-fonts` | List all available fonts |
| `ghostty +list-fonts --family="JetBrains"` | Search fonts by family |
| `ghostty +list-themes` | List built-in themes |
| `ghostty +list-keybinds` | Show current keybinds |
| `ghostty +list-keybinds --default` | Show default keybinds |
| `ghostty +validate-config` | Validate config file |
| `ghostty +version` | Show version |
| `man ghostty` | Full documentation |
## Built-in Keybindings
| Keys | Action |
|------|--------|
| `Cmd+N` | New window |
| `Cmd+T` | New tab |
| `Cmd+W` | Close tab |
| `Cmd+D` | Split right |
| `Cmd+Shift+D` | Split down |
| `Cmd+]` / `Cmd+[` | Next / previous split |
| `Cmd+Shift+Enter` | Toggle fullscreen |
| `Cmd+,` | Open config (if editor is set) |
| `Cmd+Shift+,` | Reload config |
| `Cmd+C` | Copy |
| `Cmd+V` | Paste |
> [!note] tmux Prefix
> `Ctrl+Space` is **not** bound by Ghostty by default, so the tmux prefix passes through without any additional configuration.
## Font Setup
The ==JetBrains Mono Nerd Font== is required for Neovim icons to display correctly. It was installed via:
```bash
brew install --cask font-jetbrains-mono-nerd-font
```
To verify the font is available:
```bash
ghostty +list-fonts | grep "JetBrains"
```
The Nerd Font variant (`Mono`) is important — it uses single-width glyphs for icons, preventing alignment issues in terminal UIs.
## Shell Integration
Ghostty's shell integration for zsh provides:
- **Prompt marking**: Ghostty knows where each command starts/ends
- **Semantic prompts**: Visual distinction between input and output
- **Command tracking**: Ghostty can report the last command's exit status
- **Cursor positioning**: Jump between prompts with keybinds
The integration is automatic — Ghostty injects a small zsh hook on startup. No `.zshrc` changes needed.
## Theme Consistency
==Catppuccin Mocha== is configured across all three tools for a unified visual experience:
| Tool | Config Location | Setting |
|------|----------------|---------|
| **Ghostty** | `~/.config/ghostty/config` | `theme = Catppuccin Mocha` |
| **[[Tmux Configuration\|tmux]]** | `~/.tmux.conf` | `@catppuccin_flavor 'mocha'` |
| **[[Neovim Configuration\|Neovim]]** | `~/.config/nvim/init.lua` | `flavour = 'mocha'` |
Ghostty includes Catppuccin as a built-in theme (no plugin needed). Available flavors: Latte, Frappe, Macchiato, Mocha.
## True Color Verification
```bash
# Should show a smooth orange gradient (not banded)
printf "\x1b[38;2;255;100;0mTRUECOLOR\x1b[0m\n"
```
If the text appears orange, true color is working. Ghostty supports true color natively — no terminal override needed.