terminal-emulator-config
Diagnose terminal input issues and review emulator configs.
- License 许可
- MIT
- 最近更新
- 2026-11-14
- Stars
- ★ 4
- Forks
- 1
01 前言 Front Matter
- name
- terminal-emulator-config
- version
- 1.0.0
- category
- devops
- platforms
- [ "linux", "macos" ]
- description
- Diagnose terminal input issues and review emulator configs.
02 资源文件 1
- 参考文档references/ghostty-macos.md4.5 KB
03 SKILL.md 正文
Terminal Emulator Config Review & Input Troubleshooting
When to use
- User reports keys/characters not working in a terminal (capital letters, special chars, Alt/Option combos, Ctrl+Shift combos)
- User asks to review a terminal emulator config (Ghostty, kitty, iTerm2, WezTerm, Alacritty)
- "X doesn't work in the terminal" where the terminal config is suspect
Core mechanisms (verified against Ghostty docs + upstream discussions 2026-08)
1. Keybinds consume input by default
Official keybind docs: "By default, a keybind will consume the input, meaning that the associated encoding (if any) will not be sent to the running program."
- A wall of
keybind = ctrl+shift+.../alt+...lines makes those combos dead in every app. - The kitty keyboard protocol does NOT override emulator keybinds (Ghostty discussion #9368) — Ghostty's own binds swallow the event first. Apps that distinguish Shift+Ctrl+X from Ctrl+X (Neovim, vim with modifyOtherKeys, Helix, fish, readline 8+, prompt_toolkit CLIs like Hermes) lose the bound combos.
- Fix pattern:
keybind = performable:ctrl+shift+c=copy_to_clipboard— only consumes when there is a selection; otherwise the key passes through to the app. Standard fix for copy/paste binds.
2. macOS Option/Alt handling
macos-option-as-altdefaults to true on U.S. Standard and U.S. International layouts — Option+letter sends Alt+escapes instead of macOS special characters (Option+u dead-key → ä/ö/ü broken). Ghostty discussion #6005: "None of the characters invoked with Alt+[character] is printed."- Alt+Shift+key macOS system shortcuts don't fire inside Ghostty at all, even with
keybind = clear(#3622) — Ghostty swallows the events. - If macOS special characters are wanted:
macos-option-as-alt = false.
3. TERM overrides degrade key protocols
- Ghostty's default
termisxterm-ghostty, deliberately xterm-prefixed because vim uses the xterm prefix to enable modifyOtherKeys (config reference, "HACK" note). - Overriding
term = xterm-256colordegrades enhanced key reporting and protocol negotiation in vim/fish/tmux. Keep the native TERM; for SSH use the built-in conversion (Ghosttyshell-integration-features = ssh-envauto-converts to xterm-256color remotely) instead of a global override.
4. Platform-specific keys
- Linux/GTK keys (
gtk-*,linux-cgroup-*) are ignored with warnings on macOS;quick-terminal-*is macOS-only. Cosmetic noise, not fatal — but a Linux config pasted onto macOS is the #1 source of "why is my config wrong" questions. Always confirm the actual platform first.
5. Duplicate settings: later line wins
- Repeated single-value keys: last occurrence wins (
clipboard-read = askthenallow→ allow). - Watch physical-key collisions: on a US layout
+IS Shift+=, soctrl+plusandctrl+shift+equalare the same trigger — later line silently wins. - Exception: repeated
font-familyis a fallback chain (primary + fallbacks), NOT last-wins. Verify before claiming.
6. Common app-chord collisions to look for
ctrl+0→ Emacs digit-argument / NUL — eaten by font-reset bindsctrl+minus→ readline undo (C-_) — eaten by font-shrink bindsctrl+shift+left/right/up/down→ macOS text selection + tab/prompt-nav conflictsctrl+shift+c/v→ vim/Neovim copy/paste patterns
7. Paste protection ≠ input broken
clipboard-paste-protection = trueshows a confirmation dialog for unsafe pastes — users perceive this as "special characters don't work" when pasting. Always ask whether the failure is typing or pasting.
Workflow
- Ask WHERE it fails: plain shell, vim/neovim, or a specific app (Hermes CLI, etc.). Plain Shift+letter in a bare shell CANNOT be broken by terminal config — check keyboard layout/IME/Caps Lock instead.
- Use the emulator's own listing tools:
ghostty +list-keybinds,ghostty +list-keybinds --default,ghostty +list-themes,ghostty +list-fonts. - Grep the config for: keybind walls, term overrides, platform-mismatched keys, duplicates, physical-key collisions.
- Verify claims against the emulator's current docs before asserting (docs change — e.g. Ghostty renamed themes to Title Case in 1.2.0).
Pitfalls
- Don't blame the terminal for plain-letter typing failures (layout/IME territory).
- Don't claim "font-family last-wins" — it's a fallback chain.
- Don't forget
performable:— the standard fix for binds that shouldn't swallow app keys. - Duplicate keybinds don't error — later silently wins.
References
references/ghostty-macos.md— verified Ghostty config-reference quotes, GH discussion findings (#6005, #3622, #9368), and the macOS config-review checklist from the 2026-08 session.
04 同仓库更多 Skills
macbook-linux-maintenance
Legacy MacBook Linux fixes: GPU wedge, reboot hang, thermal.
governance-regression-triage
Triage a host's governance issues: what changed.
enforcement-immutability
Use when enforcement files lose their immutable flag.
steadfaste-fleet-repo-deploy
Use when committing to the steadfaste-fleet repo.
steadfaste-fleet-maintenance
Maintain an installed Steadfaste Fleet instance — update both the upstream Hermes Agent and the fleet repo layer, merge diverged histories, sync skills safely, and troubleshoot common issues. Covers the dual-update workflow (hermes update + fleet-update.sh), encrypted brain data backup, mycortex import, and recovery techniques.
fleet-preflight
DEPRECATED alias — merged into survey-before-action (2026-08-20). Load survey-before-action instead; its "Repo-Specific Pre-Flight" section covers git search, Hermes boundary, and deployment verification.